ActionScript 2.0 :: Call A Function From Dynamic Text?
Mar 31, 2003
i'm trying to call a flash function from dynamically loaded html text.i remember seeing how to do it on a forum a while back. but i don't remember where. i think you called it kind of like an href tag but it was a little different.to clarify: i'm loading in some dynamic text into flash, i want to make a button on some of that text that will call a custom flash function.............no buttons.
I have this class where I have a dynamic function name, but I don't understand how to call it, I'm getting all kinds or errors, but most the Incompatible Override and Duplicate function definition.Here's the class:
I have an external swf(s) loaded in a main swf container. I am trying to create templates for non-coders. The main swf loads "pages" based on the currentFrame number. i.e. if on frame 12 load "m1_012.swf"I need the function call to the main swf to be dynamic.The variable function call doesn't work in the following code. The last function call does work. How can I "eval" the variable function call?
var parentObj:Object = this.parent.parent.parent; var tempFrame:Number = parentObj.currentFrame; var funcName:String = parentObj+"moreInfo_"+tempFrame;
i have created a class that so far works great. what i need to do is get that class to accept a function as one of its parameters. so for example:
[Code]...
and when the class is finshed to use the passed function name to call a internal function in the flash movie I don't even know where to begin or what its called to even do a search on it.
I have a problem: I'm trying to have a dynamic text box (htmlText) with a number of links (all dynamically generated themselves) within. I need some way that the html link can detect the user mousing over/off of it and fire off a function (to bring up a tooltip elsewhere on the interface, specifically). Is this at all possible in ActionScript 1.0?
I am making a Scrollbar component and I want a script to call a calculation function for resizing the scrollbar when a new data is loaded.I was experimenting with Object.watch but it's use is beyond me. I don't understand if its the thing I need.Can Object.watch call a function when say a dynamic textfield's data is changed?
i want to be able to type the name of a function and it's arguments, click a button, and have the function executed with said arguments
is this possible?
Something like this:
An input box and a button, button is clicked and function "function1" is called with arguments "hello" and 1 alternately i could have more than one text box, one for the function name, and others for the arguments, if that'd be easier.
I have XML displaying in dynamic text boxes. Some of the text are a href links, I also want to track which links are clicked by sending a javascript call to Google Analytics. Is there a way to do it and also open the link in a new window?
here is my code public function loadtext():void{ var text_arry:Array=new Array(xmldata.child(0).name); student_name.text=String(text_arry); } I called this function inside my timeline action window. but it is not working it said undefined...
I made a simpletext file and used the loadVariablesNum() script in flash to call that file into dynamic text boxes within my flash piece. that's all fine and dandy but now the problem is that I don't know how to make links in that simpletext document to link to specific parts of my flash movie. Basically, I need the simpletext document to have words that you can click that will take you to another frame that has another dynamic box in it with more text.
i am not an action script developer nor flash designer, i just want to have a small action script sample that i will edit a little to make it interact with my javascript code. By the way, i want to have a button and a label on a flash form, when the user clicks on this button the onclick event will call another function 'setText for example' this setText() function will change the label text. So i think the code will be something like this:
[Code]....
I managed to put the button and the label i want just the code i will write to make this work.
I get the alert but I can't get the lightbox window to display. When my as code makes the ExternalInterface call I get what looks like a page refresh and a blank browser window.
I have an enterFrame action that I use on a graphic:
[Code]....
Because I want to use the above code more than a few times, I tried to make it a function.
[Code]....
But for some reason the function call does not work when I call it via an action on a graphic where initially the code worked when it was explicitly written and not called as a function.
I need to get a javascript var in my Flash application. I like to be able to just set a variable in the javascript (client constraints) rather than define a function.
Can this be done? I am trying to use the ExternalInterface.call()
I want to make link from a dynamic text(in flash project) to an external swf i created(a gallery that is controlled by xml file). This is the code of first frame of my fla project:
url="edit"; loadVariablesNum(url + "_main.html",0); _root.link=1; function linkgal() { loadMovieNum("gal_car.swf", 1);
I've always wanted to figure this one out. If I have a dynamic text field with HTML text or even without, can I create a link that executes a function within Flash? I know I can create a link to itself with a variable and pass that variable through javascript and have it run, but that requires refreshing the browser. Is there a more seamless way to do it?
have a node that has an asfunction embedded - won't work. if I change the a href to a web page- it works fine. If I try to call a custom function it doesn't call it at all.
In a mc is a dynamic textfield, trough as this textfield gets his content. The textfield works fine and also the html text displays/works as supposed. No problem at all. But now I put a rollOver/Out on this mc with the textfield, the text shows up allright, but the html doesnt work anymore (I mean the hyperlinks, the rest is okay)
Code: textmc.textarea.html = true; textmc.textarea.htmlText = "<a href='[URL]'>link here</a>" textmc.onRollOver = function() { trace("hover on textfield"); }; textmc.onRollOut = function() { trace("going off textfield"); }; So the problem is the rollOn/Out, if I comment out those functions everything is okay...
i am trying to apply setTextFormat function for my dynamic text filed in as 3, but its not taking. look at my code and suggest me where i am going wrong.
I am using a gallery written in AS3.0 called SlicedCubeGallery. It used Flex to publish the gallery.I can edit the functions for the SlicedCubeGallery, and the one I am targeting is the one that swaps the images (which I have running on a timer).I am loading the whole gallery SWF onto my stage using this code:
var request:URLRequest = new URLRequest("slicedCubeGallery.swf"); cubeGallery_mc.load(request); addChild(cubeGallery_mc);
I have a flash movie with a dynamic loading textfield formatted in html. What I'm looking to do is format (using a tag?) the loaded html code to have a hyperlink (<a href?>) gotoAndPlay(2) or perform other functions.