Setting Flash variables from Javascript

Does anyone know the correct syntax for setting a variable on _root using Javascript?

The Macromedia site says:

<!-- javascript

movie.SetVariable("/:varname", “varvalue”);

However, this notation is quite old. I haven’t been able to get it to work. Anyone with experience here?

Cheers,

Mike

Instead of using Flash 4 notation to manipulate root variables, I simply had to name the variable:

movie.setVariable(“name”, “value”);