Can ActionScript be used to pass info to JavaScript?

I need a way of getting an often-changing 256 character string of data
into a JavaScript. Ordinarily (of course), I'd just put the string into a
separate, external file and call it in using <script src="256characterstring.js">.

Problem is, I'm prohibited from using iframes, javascript includes, etc.
But I can use Flash.

So my question is this... can the 256 character string be embedded
somehow into a flash file in such a way that it can be read and acted
upon by Javascript?

Knowing absolutely ZIP about ActionScript, it would seem like you could
create something and give it a title of "1234567890...." and then
using DOM inside of JavaScript get the title of that object.

If that makes ANY sense at all.. I appreciate your comments, feedback.

Who is Participating?
There are a few different ways you could do this, here is a web site to look at for some examples:

One easy way to do it is to create a text box on your flash file somewhere and call that variable value in javascript.  Here is the javascript code:

Also, you can call a javascript function from flash
Ex: getURL("javascript:parent.Main.Receive();","Main");

If needed, you could pass values in the function call

Hope this helps,
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.