Flashvars Purgatory

Hey Guys…

Ive been hitting my head against the wall all day on this issue… (and im starting to bleed…)

I need to be able to pass a variable from the Html page itself , to the Flash movie on that page… using the < PARAMETER NAME=“FlashVars” Value=“myName=Darrel”> tag in html.

I tried searing thru macromedia, and this forum looking for examples that work but have failed. (please dont give me the link to macromedia i know that link too well) …

I just need help…

Im using Flash MX (not 2004) and flash player 6…

Is this possible? or am i just wasting my time on an impossible task.

And if it is possible, can you send me an example that has a html page and a flash movie with the action script so i can assimulate the code?

Much advanced Thanks.

it will probably be easier to use a url variable

I cant get that to work either, but because of the way this is built, i need to get the variable thru flashvars.

Nobody else has any clue?

Ok i got it to work…

And for those out there who are having the same problem as me… Heres what i didnt do…

I didnt find this bit of important information on macromedia’s site… hehe =)

Heres what you do, on your html page you put this tag where the other param tags go.:

[AS]
< PARAM NAME=FLASHVARS VALUE=“myName=raydred”>
[/AS]

and you have to add this to inside the Embed object… ex:
[AS]
<EMBED src=“myMovie.swf” quality=high … … FLASHVARS=“myName=raydred” >
[/AS]

Once that happens, it is automatically propagated to your flash movie on that page when it loads.

Now to access your variables use the _level0 … ex:
[AS]
_level0.myName;
[/AS]
so now i can use my name in flash…

Also you can define mutliple vars by using the & in the flasvars value, ex:

flashvars = “myVar1=val1&myVar2=val2&myVar3=val3”

browsers can support up to 64KB (65535 bytes) in length.

So There is my Tute, and it works. And i finally figured it out =)

Thanks for your help guys =)