Tuesday, December 20, 2005

Coca-Cola = Cocaine-Cola

Claim: Coca-Cola used to contain cocaine.
Status: True.

Coca-Cola was named back in 1885 for its two "medicinal" ingredients: extract of coca leaves and kola nuts. Just how much cocaine was originally in the formulation is hard to determine, but the drink undeniably contained some cocaine in its early days. Frederick Allen describes the public attitude towards cocaine that existed as Coca-Cola's developers worked on perfecting their formula in 1891:

The first stirrings of a national debate had begun over the negative aspects of cocaine, and manufacturers were growing defensive over charges that use of their products might lead to "cocainism" or the "cocaine habit". The full-throated fury against cocaine was still a few years off, and Candler and Robinson were anxious to continue promoting the supposed benefits of the coca leaf, but there was no reason to risk putting more than a tiny bit of coca extract in their syrup. They cut the amount to a mere trace.
Allen also explains that cocaine continued to be an ingredient in the syrup in order to protect the trade name "Coca-Cola":

But neither could Candler take the simple step of eliminating the fluid extract of coca leaves from the formula. Candler believed that his product's name had to be descriptive, and that he must have at least some by-product of the coca leaf in the syrup (along with some kola) to protect his right to the name Coca-Cola. Protecting the name was critical. Candler had no patent on the syrup itself. Anyone could make an imitation. But no one could put the label "Coca-Cola" on an imitation so long as Candler owned the name. The name was the thing of real value, and the registered trademark was its only safeguard. Coca leaves had to stay in the syrup.
How much cocaine was in that "mere trace" is impossible to say, but we do know that by 1902 it was as little as 1/400 of a grain of cocaine per ounce of syrup. Coca-Cola didn't become completely cocaine-free until 1929, but there was scarcely any of the drug left in the drink by then:

By Heath's calculation, the amount of ecgonine [an alkaloid in the coca leaf that could be synthesized to create cocaine] was infinitesimal: no more than one part in 50 million. In an entire year's supply of 25-odd million gallons of Coca-Cola syrup, Heath figured, there might be six-hundredths of an ounce of cocaine.
So, yes, at one time there was cocaine in Coca-Cola. But before you're tempted to run off claiming Coca-Cola turned generations of drinkers into dope addicts, consider the following: back in 1885 it was far from uncommon to use cocaine in patent medicines (which is what Coca-Cola was originally marketed as) and other medical potions. When it first became general knowledge that cocaine could be harmful, the backroom chemists who comprised Coca-Cola at the time (long before it became the huge company we now know) did everything they could with the technology they had available at the time to remove every trace of cocaine from the beverage. What was left behind (until the technology improved enough for it all to be removed) wasn't enough to give a fly a buzz.

Have to realy realy stop drinking this, No one knows the secret formula for Coca Cola !!!

Sunday, December 18, 2005

How to open windows in the same browser control

The problem: how to make a browser control on a form, that will not open new windows after clicking a link with the _blank in the target property. It will open the same form (your form with the browser control).

Make form, put a Browser control

Forms Name = frmBrowser
Browser Control Name = AxWebBrowser1

Then just copy paste the this method in the form code.

Private Sub AxWebBrowser1_NewWindow2(ByVal sender As Object, ByVal e As AxSHDocVw.DWebBrowserEvents2_NewWindow2Event) Handles AxWebBrowser1.NewWindow2
Dim frmWB As frmBrowser
frmWB = New frmBrowser(Me._URLClicked)

frmWB.AxWebBrowser1.RegisterAsBrowser = True
e.ppDisp = frmWB.AxWebBrowser1
frmWB.Visible = True
End Sub

Wednesday, December 07, 2005

How to Handle Click events of AxShockwaveFlash cotrol in .Net

Raise an event from Flash movie, and catch it in you application in the FSCommand handler

1. In your Flash movie you set this event for a button.

// This is an actionscript and to use it you need for Macromedia Flash
on (release) {
//On clic event
fscommand("exec", "Click_01");

2. Then in your Vb. Net application you catch the event

Private Sub AxShockwaveFlash1_FSCommand(ByVal sender As Object, ByVal e As AxShockwaveFlashObjects._IShockwaveFlashEvents_FSCommandEvent ) Handles AxShockwaveFlash1.FSCommand

If e.args.ToString = "Click_01" Then
MessageBox.Show("OK, an event occours")
End If

End Sub

How to reset a Seed Value in SQL Server

DBCC CHECKIDENT ( TableName , RESEED , NewSeedValue )

Simple, i didnt think it was this simple :D

Enjoy IT!

Thursday, December 01, 2005

Backup databases stored procedure using SQL LiteSpeed - new version

A lot of good information on Database Procedures that i didnt know about, like the registry, making directories, checking directory exists, and file exists.

And a very usefull procedure. Hope it helps