Hi Kerry, Digging a few years back, I unearthed some code.
Here's the html: <object data="main.swf" id="main" type="application/x-shockwave-flash" width="980" height="600"> <param name="movie" value="main.swf" /> <param name="menu" value="false" /> <param name="quality" value="best" /> <param name="bgcolor" value="#ffffff" /> <param name="flashVersion" value="9" /> <param name="flashVars" value="product=test"/> </object> And this is from the Main Class constructor: product = root.loaderInfo.parameters.product; For the life of me I can't remember why I used root in a Main constructor (copy-pasta from another class or maybe the movie was loaded by another?), but it worked. Maybe you could try this combo with a bare-bones test movie. (Note: This wasn't done in FlashBuilder, though - Flash IDE compiler with FlashDevelop for code editing) Karina -----Original Message----- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Kerry Thompson Sent: 01 May 2012 06:22 To: Flash Coders List Subject: Re: [Flashcoders] Accessing FlashVars That's one way of doing it, but the embed tag has been deprecated. Well, maybe not officially deprecated, but it's considered obsolete. I've done some more digging, and it may not even be related to the FlashVars. There are some other things in the HTML that aren't working, so there may be a deeper, or prior, problem. Thanks, Karl. Cordially, Kerry Thompson On Tue, May 1, 2012 at 1:12 AM, Karl DeSaulniers <k...@designdrumm.com>wrote: > Something like this? > > <object> > ... > <param name="FlashVars" value="appURL= test&appURL2=hello"> ... > > <embed ... FlashVars="appURL= test&appURL2=hello" ... /> </object> > > > FLASH --- > > function init(e:Event) { > var flashVars=this.loaderInfo.**parameters; > var appURL=flashVars.appURL; > } > this.loaderInfo.**addEventListener(Event.**COMPLETE, init); > > HTH, > Karl > > > On Apr 30, 2012, at 5:46 PM, Kerry Thompson wrote: > > Flash Builder 4 AS3 project, Windows 7, Firefox 12.0. >> >> I can't access the FlashVars in the HTML file. I've been working on this >> all day, and it's driving me crazy (crazier). Do you see anything in the >> following code? >> >> In the constructor of my default AS3 file, I have this: >> >> this.loaderInfo.**addEventListener(Event.**COMPLETE, init); >> >> and in the init() function: >> >> var flashVars:Object; >> >> flashVars = this.loaderInfo.parameters; >> >> When I look at it in the debugger, flashVars is an object, but it has no >> parameters. The relevant HTML is pretty straightforward: >> >> <object classid="clsid:D27CDB6E-AE6D-**11cf-96B8-444553540000" >> width="100%" height="100%" id="RMK_Beta"> >> <param name="movie" value="RMK_Beta.swf" /> >> <param name=FlashVars value="appUrl=test" /> >> <param name="quality" value="high" /> >> <param name="bgcolor" value="#ffffff" /> >> <param name="allowScriptAccess" value="sameDomain" /> >> <param name="allowFullScreen" value="true" /> >> <!--[if !IE]>--> >> <object type="application/x-shockwave-**flash" >> data="RMK_Beta.swf" width="100%" height="100%"> >> <param name=FlashVars value="appUrl=test" >> /> >> <param name="quality" value="high" /> >> <param name="bgcolor" value="#ffffff" /> >> <param name="allowScriptAccess" value="sameDomain" /> >> <param name="allowFullScreen" value="true" /> >> <!--<![endif]--> >> <!--[if gte IE 6]>--> >> <p> >> Either scripts and active content are not permitted >> to run or Adobe Flash Player version >> 10.0.0 or greater is not installed. >> </p> >> <!--<![endif]--> >> <a href="http://www.adobe.com/go/**getflashplayer<http://www.adobe.com/go/getfl ashplayer> >> "> >> <img src=" >> http://www.adobe.com/images/**shared/download_buttons/get_** >> flash_player.gif<http://www.adobe.com/images/shared/download_buttons/get_fla sh_player.gif> >> " >> alt="Get Adobe Flash Player" /> >> </a> >> <!--[if !IE]>--> >> </object> >> <!--<![endif]--> >> </object> >> ______________________________**_________________ >> Flashcoders mailing list >> Flashcoders@chattyfig.figleaf.**com <Flashcoders@chattyfig.figleaf.com> >> http://chattyfig.figleaf.com/**mailman/listinfo/flashcoders<http://chattyfig .figleaf.com/mailman/listinfo/flashcoders> >> > > Karl DeSaulniers > Design Drumm > http://designdrumm.com > > > ______________________________**_________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.**com <Flashcoders@chattyfig.figleaf.com> > http://chattyfig.figleaf.com/**mailman/listinfo/flashcoders<http://chattyfig .figleaf.com/mailman/listinfo/flashcoders> > _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders