Using SwfObejct I need to pass a variable within an ASP page to Flash to load text into a dynamic text field. I have posted my ASP and my AS3. I dont know much ASp so any help would be greatly appreciated… The goal: to load an ASp determined line of text into “important_mc.reminder”… “important_mc” is the mc on the stage and “reminder” is the dynamic textfield within… I believe this AS3 is only reading the SwfObject variable…
Thanks again for all the input…
AS3:
var reminder = root.loaderInfo.parameters.reminder;
root.loaderInfo.addEventListener(Event.COMPLETE, onLoaderInfoComplete);
function onLoaderInfoComplete(e:Event):void {
reminder = root.loaderInfo.parameters.reminder;
trace(root.loaderInfo.parameters.reminder);
var allFlashVars:Object = LoaderInfo(this.root.loaderInfo).parameters;
}
ASP (classic):
<% Set rs = conn.execute("Select * from insertfiles where id=52")
reminder = rs("insertfilehtml")
rs.Close
'response.write inserthtml
%>
<script language="javascript">AC_FL_RunContent = 0;</script>
<script src="AC_RunActiveContent.js" language="javascript"></script>
<h1><a href="index.asp">Apartment association GREATER DALLAS</a></h1>
<%if reminder<>"" AND reminder<>" " AND reminder<>" " then%>
<div class="important-info">
<script type="text/javascript" src="js/swfobject.js"></script>
<div id="flashcontent"> This text is replaced by the Flash movie. </div>
<script type="text/javascript">
var so = new SWFObject("flash/important.swf", "important", "575", "30", "9", "#ffffff");
so.addVariable("reminder", "<%= linkName %>");
so.addParam("wmode", "transparent");
so.write("flashcontent");
</script>
</div>
<% end if %>