Skip to main content
February 25, 2007
Question

Problem with SetVariable Flash method

  • February 25, 2007
  • 1 reply
  • 386 views
Hello folks,

I have this function on the <head> of my HTML:

<script language="JavaScript" type="text/javascript">
function GivemetheURL () {
window.document. myFlashMovie.SetVariable("_global.strURL", document.location.href);
}
</script>

My flash movie has only one frame with a dynamic text field named myfield. The actions defined on that frame are:

getURL("javascript:GivemetheURL();");
_root.myfield.text = _global.strURL;

Why this doesn't work and I get undefined for _global.strURL?
I've already modified flash player global security settings to allow Javascript calls on that movie...

Thanks in advance!
This topic has been closed for replies.

1 reply

February 26, 2007
Have you tried defining _global.strURL? as in:

var _global.strURL:String;