0

I have an external interface call which should retrieve some text from the html that the swf is embedded in.

var name:Object = flash.external.ExternalInterface.call(
    "function(){return JSObject.get('Resource', 'name');}");

When I put the variable name into a textbox I get the correct text.

when I use geturl with a clickTag, under some circumstances it works (unencoded clickTag url). Sometimes it's undefined (encoded clickTag urls). If I use name.toString then it opens http://www.someurl.com/[type%20Function] or displays [type%20Function] in a textbox.

So I suspect that I'm having encoding issues when passing on the clickTag url. My question is, how do I convert this object to a string or assign the contents of the object to a string variable to avoid all this?

Thanks

Amarghosh
  • 58,710
  • 11
  • 92
  • 121
Dave
  • 1
  • 1
  • 2

1 Answers1

0

if you use name.toString you are referring to the function definition, that's why you're getting [type%20Function]. use name.toString() instead

user151496
  • 1,849
  • 24
  • 38