How to write a program to show the external actionscript?
Answer / Rajesh Singh Rana
"To run an external ActionScript file, you need to load it using the Loader class. Here's an example:nnimport flash.display.Sprite;nimport flash.net.URLRequest;nimport flash.events.Event;nnclass Main extends Sprite {n private loader:Loader;nn public function Main() {n // Create a Loader instancen this.loader = new Loader();n // Configure the URL request for the external AS filen var request:URLRequest = new URLRequest("example.as");n // Attach event listenersn loader.load(request);n loader.contentLoaderInfo.addEventListener(Event.COMPLETE, onComplete);n }nn private function onComplete(event:Event):void {n // Access the loaded SWF or AS filen var swf:MovieClip = MovieClip(loader.content);n // Add it to the display listn addChild(swf);n }n}
| Is This Answer Correct ? | 0 Yes | 0 No |
what methods are used to pass variables out of flash to a server side solution? : Adobe flash
tell the difference between indexed array and associative array? : Adobe flash
which of cannot be automatically outputted by the trace action? : Adobe flash
what is generally considered the ideal group size for usability testing? : Adobe flash
Give an example that illustrates polymorphism in flash script.
what is the difference between document class and main time line class in action scirpt-3
how does an xmlsocket server know when a received message is complete? : Adobe flash
explain the flash vs. Animated images and java applets? : Adobe flash
How many methods for depth are available?
Do you know what is the difference between an array and vector?
Difference between shared lib and shared objects
at which point can you start usability testing? : Adobe flash