I am trying to create a quiz for an educational site I'm working on. The quiz itself is in flash and uses FS commands to report the score to the HTML page. Unfortunately, every time I try it, it causes my browser to crash. I'm still learning javascript, so that could be the problem.

The name of the movie is "testmovie" and here is the code I am using:

function testmovie_DoFSCommand(command, args)
{
if ( command == "score" )
document.write(+ args);
}

I'm also using some VBscript:

<!--
// Catch FS Commands in IE, and pass them to the corresponding JavaScript function.

Sub testmovie_FSCommand(ByVal command, ByVal args)
call testmovie_DoFSCommand(command, args)
end sub

//-->

Any ideas? I'd appreciate any help anyone could give. And I apologize if this is a stupid question.

Thanks, Jaime