swfloader

Load remote swf files in flex

I have a SWFLoader in mxml of my flex app. <mx:SWFLoader id="swfPreview" width="100%" height="90%" y="20" visible="false"/> Now on a button click, I execute the following code in action script. swfPreview.addEventListener(Event.COMPLETE,loadComplete); swfPreview.scaleContent = true; swfPreview.load(url); Where "url" is the url ...

Flex 3 (Action Script): How to access a function from a loaded swf-file ?

Hi, i load in ActionScript a swf file. So far no Problem, but I didn't found a way to access one of it's functions, the best thing would be if I could access the main function in the mxml part of the swf. Here is the code of the main-mxml file that belongs to the swf that should load and access another swf: <?xml version="1.0" encodin...

Load external swf from a button in external swf and unload self?

Hello, I am an uber n00b to flash AS3. And it is not my intention to sound like a complete moron, but honestly, I have had a hard enough time figuring out just how to load an external .swf into my main file! And now my friend is asking me if I could please add a button within the external .swf which will unload itself and load a new on ...

flex 4: swfloader - how to mute game completly

Hiya. Ive read some answers here regarding muting swfloader volume but none of the examples would work in flex 4. I tried doinf the following: this._swfGame.source=url; this._swfGame.soundTransform = new SoundTransform(0.0); this would shut down the volume of the preloader, but when the game starts the volume is back to normal. i tr...

embedded SWF isn't shown (SWFLoader)

I embed a swf as ByteArray and load it at runtime with the SWFLoader. Here is the internal swf that I want to load: <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"> <mx:Label id="rLabel" text="From InternalSWF"/> </mx:Application> The embeding swf loads it with t...

SWFLoader - "SWF all over the place"

I need to load in an swf component but I want it to be an exact width and height, problem is that when I set width and height it doesn't matter, content of that swf still goes out of predefined bounds. How can I tell it not to do so, so it will work exactly as in html document embed? ...

How to specify arguments to a SWF loaded using a SWFLoader whose source was a ByteArray?

When a path is specified as the source argument of a SWFLoader, arguments can be appended to the path so that the SWF runs with the desired arguments. <mx:SWFLoader id="mySwf" source="pathOfSwf.swf?arg1=1"/> How do you do the same thing when instead of a path you specify a ByteArray as the source argument of a SWFLoader. <mx:SWFLoade...

How to access the values in a datagrid present in one application, using the cut, copy, paste buttons present in another application.

One application is loaded from the other using SWFLoader. ...

how to access flex component id's generically?

I have some generic functions like copy, paste,etc in an AS file. I want to use them for editing data present in different mxml applications embedded in one application. If I pass the child's component id as a parameter of a function in one of the events, I get the value as either null or the parent app name. But I want the id of the chi...

flex4 swfloader: how can i paste parameters to the loaded swf application ?

Hiya. When i load an swf application using SWFLoader in Flex 4, how can i paste parameters to that application ? thanks! ...

flex 4 swfloader: if loading a game played with mouse not on x=0,y=0 bad mouse coords

Hiya. I'm creating a container for flash games. When I load a game using SWFLoader component at x=0 y=0, the game runs properly, but when i load the game at x=500 and y=500 for example, the mouse coords that are returned to the game are false. instead of the mouse i see the game character properly in the right place, but the game itsel...

flex 4 swfloader: SWFLoader.content.stage.width and height returns the main stage width and height

Hiya. When I load a flash application using SWFLoader, the Stage width and height of the loaded application becomes the stage of the main flex application. so if i created a game that uses stage width and height to calculate where to draw, it actually draws outside of the bounds of the loaded application stage because it gets the width ...

Creating a swf from a set of images

I have a set of images, and I want to show them as a SWF slideshow. Something similar to Slideshare.net It would be easiest if there is way I can pass a xml or json with list of images, and get the swf. I there a library or (linux friendly) tool, which I can use to do this? I am using Python with Django, but am open to using other langu...

flex: trouble resize and position SWFLoader

I have a complicated problem with a couple of SWFLoaders. I have an application that loads a swf with a SWFLoader. The loaded swf loads another swf (just a compiled fla). I am adding all my resize and position logic in my loaded swf and it works good on event resize, but when I'm trying to run the same code in my swfs applicationComplet...

Flex 4, SWFLoader border resize issue

Hi, Following is the issue i am facing. I have a MainPage, on initialize I am calling a method which would create a SWFLoader object (aka LoginPage) and loads it in the MainPage. When we run the MainPage in 800x500 window, the LoginPage loads in that window size, however when we maximize the window the content of the LoginPage gets re...

flex 4: resize SWFLoader element to fit inside a VGroup element

Hello. I'm trying to resize a flash game inside a VGroup, no matter what configuration i try to set, some of my flash games are clipped out. i see only 80% of the actual flash screen. this is my code: <s:VGroup id="gameVGroup" clipAndEnableScrolling="true" height="480" maxHeight="480" width="540" maxWidth="540"> <mx:SWFLoader ...

ActionScript 3.0 how many loaders?

Hi, I want to load 2 different elements on my flash video: First is a dynamic photo (I take the specific number from an external variable) Latter is a swf video... My question is? I'm new to AS3, I saw that I need a loader and I can load everything.. but how many loaders I must have? Can I use only one changing the function called on ...

Class in loaded SWF cannot use base class in loading SWF

I have two SWF files which I shall call container and slave. The slave file contains a movieclip that extends from a class I shall call base. base extends MovieClip and is compiled into an SWC. slave includes this SWC as a runtime library, while container includes it as merged (and does reference it so it should be compiled into the cont...

Unloading swf from parent swf

Hey guys So I loaded a swf into another swf like so correctURL being my external swf variable function startLoad(){ var mRequest:URLRequest = new URLRequest(correctURL.toString()); mLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onCompleteHandler); mLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, onProgre...

get the event when the loaded movieclip is ready in the right frame

Hi, i'm developing an app that use swf to load elements and add properties to the loaded swf. I use SWFLoader to load the movie and on the COMPLETE event i move the loaded MovieClip to a specific frame and then list its DisplayList. I've discovered that if i traverse the list soon it's note loaded. Maybe it's cleaner with code: loader....