Access .swf in MovieClip

Hi,
I have to access different frames from swf file in flex.means
when mouseover on canvas it should load frame 5.I know through
movie clip i can goToPlay particular frame.But how can I access swf
through movieclip.
Thanks,
Megha

Store the swf file in the src/mimes/Components directory
Retrieve the URL of this file using
WDURLGenerator.getResourcePath(wdComponentAPI.getDeployableObjectPart(), YourCompView.FILE_NAME)
and store this URL in a context attribute
Bind the IWDIFrame 'source' property with the stored URL context attribute, and set the iFrame's 'lifeCycle' property to 'uielement' in order to prevent refresh of the content during server roundtrips
Upon clicking the button, you can show/hide the iFrame and thus enabling your swf file

Similar Messages

  • Can i access swf files with your product?

    can i access swf files with dreamweaver?

    You will need Flash as well as Dreamweaver.
    Follow these instructions http://help.adobe.com/en_US/dreamweaver/cs/using/WSc78c5058ca073340dcda9110b1f693f21-7ad0a .html

  • How access SWF Library items?

    Is it possible to access SWF Library items from main FLA?
    Ex:
    I am loading swf on level1, i want to access level1 library
    items from level0 file

    You'll need to get the FLA for the file to see how the
    linkage is set up. Other option, though not ideal, is to get ahold
    of a SWF decompiler, and create a new FLA where you know the
    linkage id's.

  • I want to load external swf in movieclip and next external swf should load Automatically

    I want to load external swf in movieclip and next external swf should load Automatically when current swf is finished in AS3.
    How can we can check total frame and current frame of imported swf in a movie clip.
    any help will be appreciated
    regards,
    Jatin Dembla

    in as3 you use the loader class (not movieclips) to load external swfs.
    you can use an Event.COMPLETE event listener (applied to the loader's contentLoaderInfo property) to check when loading is complete and start the next swf loading.
    you can use the loader's content property (caste as a movieclip) to determine info (including totalFrames) about the loaded swf's main timelnie (once loading is initialized, for the totalFrames, or complete, for some other properties like height and width).
    var loader:Loader=new Loader();
    loader.contentLoaderInfo.addEventListener(Event.COMPLETE,loadcompleteF);
    loader.load(new URLRequest("swf1.swf"));
    var loadedSWF:MovieClip;
    function loadcompleteF(e:Event):void{
    loadedSWF=MovieClip(loader.content);
    trace(loadedSWF.totalFrames);

  • Loader Class access .swf content

    Hi!
    I am having trouble accessing a MovieClip from a .swf file
    that I load in my main movie.
    I use a code similar to the one bellow, and
    myMovieClip is a MovieClip placed directly on the stage of
    my .swf file.
    I would apreciate a little help on this.
    Thank you!

    Thanks, AlbertG! I did, indeed, do that, but it didn`t
    work...
    It gave me an error that I was trying to access a proprety of
    loader that didn`t exist. But the way to get around it is(at
    least it worked for me):

  • Call function, pass value, access variable in movieclip class from main stage

    i am new to flash as.
    I got quite confused on some problems. as the function here
    is quite different from c and asp.net.
    I have a movieClip named MC, and it's enabled with action
    script, with the class name MC_Rectangle
    and a Stage.
    I override the MC_Rectangle class file in a mc_rectangle.as
    external file.
    here is the code:
    package{
    import flash.display.*;
    import flash.events.*;
    public class MC_Rectangle extends MovieClip {
    var sequence:int = new int();
    function setSequence(data:int):void{
    sequence = data;
    function addSequence():void{
    sequence ++;
    I have new a object in the main stage var
    mc_rect:MC_Rectangle = new MC_Rectangle()
    question:
    in main stage:
    1. how can i access the variable "sequence" in "mc_rect"
    2. how can i pass parametre from main stage to mc_rect via
    function setSequence(data:int)?
    3. how can i call the function in addSequence() in mc_rect.
    in asp.net, i usually use mc_rect.sequenct,
    mc_rect.setSequence(data), mc_rect.addSequence() to achieve my
    goals......
    btw, can function in mc_rect return out result to main stage?
    thanks in advance.

    Your as-file must be named MC_Rectangle.as (same upper/lower
    case as in the Class name)
    Ad 1) You have to declare sequence as a public property
    "public var sequence;" or - better - define a getter-function for
    sequence.
    Ad 2) mc_rect.setSequence(8); e. g. (you must write "public"
    in the Class-declaration of setSequence)
    Ad 3) mc_rect.addSequence(); e. g. (you must write "public"
    in the Class-declaration of addSequence)
    ... and yes, your methods can return a value: Replace "void"
    with the proper data type (int, String, ...) and place a "return
    myNumber;" or the like in the method's body.

  • Can't convert the swf to MovieClip

    I have a problem where i have an as3 project loading in an
    AS3 SWF which contains another AS3 SWF containing a videoplayer,
    and i'm getting the type coercian fail error as above.
    TypeError: Error #1034: Type Coercion failed: cannot convert
    work_client_overlay@39e9e0b1 to flash.display.MovieClip.
    at WorkClient/externalLoadComplete()
    at Function/
    http://adobe.com/AS3/2006/builtin::apply()
    at MethodInfo-37()
    usually when i load in an SWF I put something like
    var mc:MovieClip - new MovieClip();
    mc = MovieClip(ev.currentTarget.content) //where
    ev.currentTarget is a loader
    Then i find that i can trigger functions inside the loaded
    SWF by using
    mc.SomeFunction();
    but this isn't working in this case and the only reason i can
    see is that there is a videoplayer loaded inside the SWf i'm now
    loading in....
    Any help would be greatly appreciated.
    Greg

    I solved it. The main class of my loaded SWF needed to extend
    MovieClip and it was only extending Sprite.

  • LoadMovie- loading an external swf into movieclip in AS3

    Im extremely frustrated.........im trying to do something
    that was once very simple, which has now become over complicated
    unecessecarily.....i want to do a simple loadMovie type action and
    load an external clip into a movieclip called ph. my AS2 code would
    be:
    loadMovie("ExternalMovieClip.swf","ph");
    or
    on(release) {
    loadMovie("ExternalMovieClip.swf","ph");
    This no longer works. Can somebody tell me the new code that
    i would use with AS3 to do exactly what i just demonstrated? I
    honestly dont even want to touch AS3. The only reason i want to use
    it is because it makes skinning the components SOOOOOO much easier
    than AS2. That is the one and only reason im trying to convert to
    AS3. All the new load movie AS3 examples ive seen on google look
    like half a page long to do what i used to do in 2 lines. There
    must be a simpler and much easier way. I am a designer. It looks to
    me like Adobe went back to making flash for programmers only again
    leaving us designers out of the mix. Someone please help me, im
    desperate. I also have other old code that im sure im going to have
    to convert to AS3 for it to still work, and i may eventually need
    help with that as well, but ill stick with this loadMovie problem
    for now. Any and all help is appreciated. Thanks

    have a look here:
    http://www.smithmediafusion.com/blog/?p=381
    use this:
    var i =new Loader();
    i.load(new URLRequest(”yourSwf.swf”));
    myMC.addChild(i)
    myMC is the name of your clip on the stage.
    Dan Smith > adobe community expert
    Flash Helps >
    http://www.smithmediafusion.com/blog/?cat=11
    http://www.dsmith.tv

  • Problem reloading swfs inside movieclip in IE

    I'm not quite sure whats going on. I have a website i'm working on http://www.tulum14.com and it works fine in safari and firefox, but when I run it in explorer it doesn't.  Whats going on is that when you go to the homes section of the site, each home's section is a swf that is loaded into the main movieclip.  In explorer these swfs load fine the first time around, but when you return and want to load the swf/section and see it again, they get stuck and although they appear to load, i'm not sure if they have and are getting stuck on the first frame or they are not loading, or there is something going on with the cache.
    I am loading from the main movieclip using a container with the following code:
    var homeLdr:Loader = new Loader();
    var homeURL:String = (MovieClip(root).gotoArea)+"Eng.swf";
    //gotoArea names the swf to load
    var homeURLReq:URLRequest = new URLRequest(homeURL);
    homeLdr.load(homeURLReq);
    homeLdr.x = -500;
    homeLdr.y = -250;
    MovieClip(root)[MovieClip(root).gotoArea + "_holder"].addChild(homeLdr);
    //each instance of the holder clip is named after the area it should load
    stop();
    the loader script to check and see if the swf is loaded before running it is:
    function progressHandler(event:ProgressEvent):void {
        var percent1:int;
        percent1 = (Math.round(event.target.bytesLoaded/event.target.bytesTotal*100));
        trace(percent1);
        if (percent1==100) {
            percent.x=539;
            this.gotoAndPlay(3);
        } else if (percent1!=100) {
            percent.x=541;
        percent.text=String(percent1);
    this.loaderInfo.addEventListener(ProgressEvent.PROGRESS, progressHandler);
    stop();
    any ideas? help?
    I appreciate it.
    Thanks
    alfarovive

    it would be best to change your preloader to the loading swf.
    but you can use your current set up:
    function progressHandler(event:ProgressEvent):void {
        var percent1:int;
        percent1 = (Math.round(event.bytesLoaded/event.bytesTotal*100));
        trace(percent1);
        if (percent1==100 || event.bytesLoaded==0) {
            percent.x=539;
            this.gotoAndPlay(3);
        } else if (percent1!=100) {
            percent.x=541;
        percent.text=String(percent1);
    this.loaderInfo.addEventListener(ProgressEvent.PROGRESS, progressHandler);
    stop();
     this.loaderInfo.addEventListener(event.COMPLETE,f);
    function f(e:Event){
    var pe:ProgressEvent=new ProgressEvent("complete");
    progressHandler(pe);

  • Loading swf into movieclip object

    I am trying to load a swf file into a movieclip object on the
    stage. The movieclip object is sized smaller than the screen, and
    placed in the middle. I have defined a loader with:
    var myMovieClipLoader:MovieClipLoader = new
    MovieClipLoader();
    then use it like this:
    _level0.myMovieClipLoader.loadClip("moviename.swf",
    _level5.movieclipinstancename);
    (the movieclip object is used in a swf loaded in level5)
    When I load the swf like this, the swf loads at the correct
    location according to where I have placed the movieclip object,
    however it "blows up" to fill the screen from that point down and
    across, ignoring the size of the movie clip object (the loading swf
    actually expands beyond it's created size to fill the screen,
    making all the graphics and text much larger than intended). The
    actual pixel size of the swf I'm trying to load matches the size of
    the movieclip object (1024x350 in a 1280x1024 screen).
    What is the magic setting or property that will tell the
    loading swf to honor the size of the movieclip object I'm loading
    into?
    Thanks for your help!
    Barb

    Something I've been working on:
    Place the following code in a new file <your project
    folder>\as\MovieContainer.as
    Then open the properties for the symbol you want to be your
    movie container
    Set the AS 2.0 Class to as.MovieContainer and give it a name
    (I named mine 'loader').
    To load the movie, simply call:
    loader.queueSWF('my.swf');
    Hope that makes sense. Basically, it's just a self contained
    class for loading into an object on the scene. It draws a simple
    progress bar on the center of the symbol when it's loading and it
    resizes the loaded object on init to conform to the size of the
    object on the stage. Why queueSWF? Well, if it's currently loading
    a SWF, it will wait till it's finished and load a new one. The
    biggest problem right now is the progress bar, but it's fairly easy
    to remove if you don't like it. Hopefully it helps.
    If anyone else is reading this. I'm trying to figure out if I
    can load these movies into an array of movieclips. So far I've had
    no luck. If you know of a way, feel free to drop some input.

  • When time line reaches a certain frame load swf into movieclip.

    Hi,
    I need some help with some actionsscript. When the timeline reaches a certain frame, I want an swf to load into a movieclip in that particular frame. I need this to occur on level 1 as the root of the site is pre loader. Any help would be much appreciated. Cheers

    In that frame, on an actions layer, use either the loadMovie method or the MovieClipLoader.loadClip method to load the swf into the movieclip.  There should be examples of using either in the help documents and via Google.

  • Load swf into movieclip // play pause buttons

    I am going out of my mind trying to get this to work. I can do it in AS2 without a hitch - but not AS3.
    I just need to load an external swf file into an empty movieclip. Then I have 2 buttons play and pause that need to be on the top layer of the new movie and they need to play and pause the loaded swf file.
    I have tried a number of things and nothing is working. Please help.
    Thank you in advance.
    Shawna

    you can use:
    var ldr:Loader=new Loader();
    addChild(ldr);
    ldr.load(new URLRequest("yourswfthatyouwanttoload.swf"));
    addChild(yourplaybtn);
    addChild(yourpausebtn);
    yourplaybtn.addEventListener(MouseEvent.CLICK,playF);
    yourpausebtn.addEventListener(MouseEvent.CLICK.pauseF);
    function playF(e:Event){
    MovieClip(ldr.content).play();
    function pauseF(e:Event){
    MovieClip(ldr.content).stop();

  • Problem loading flv over network when accessing swf through html

    hi all,
    i have website that loads images and videos for my company.
    it's an internal thing that's meant to be shown in a network folder
    that people can access.
    my problem comes when i try to load videos in. on my local
    machine, everything works fine, if you launch the swf directly from
    the network folder, everything works fine. the problem comes when
    you launch the html that the swf is embedded in. my netconnection
    is successful, but when i try to load the flv using netStream.play
    (using a local path like "videos/myVid.flv") if get a
    NetStream.Play.StreamNotFound error.
    local paths work fine when loading images etc but not videos
    (even when i put the video into the images folder or vice versa).
    the only way i can get this working is if i put absolute paths into
    the video ( like "\\myServer\flash\videos\myVid.flv")
    i'm thinking this is a sandbox problem. when you open the swf
    directly, it's running on the network, so it's ok to access network
    files, but when you open the html, it's being loaded to your local
    computer, and isn't able to do it? both times when i print out the
    sandbox type it's "localWithFile", but it just doesn't work in the
    browser. but then i don't get why xml loading and image loading
    works, but not video. i've also changed the export to
    localWithNetworking and tried Security.allowDomain("*") but nothing
    worked.
    this works fine if the files are uploaded to a webserver,
    btw.
    i've
    put
    up a zip file with the relevant files (though you'll have to
    stick in your own flv), though unless you have a network handy it's
    going to be a bit hard to test it.
    any help or points in the right direction would be
    appreciated though
    thanks

    Your files work fine with my FLV and when I try to follow
    your instructions. Two days ago we had a situation that was almost
    like what you've described, except that the swf would work, the
    html work work (when opened directly, like
    "file:///Users/colin/Desktop/video%20bug/video_bug.html", but would
    not work when opened via http. If that is your real situation then
    you may have the same issue we had, which is that our server had
    its MIME type set wrong for handling FLVs.

  • AS3 sucks !!! Why can't access a simple movieClip ???

    Hi People,
    Please - it's as simple as that:
    I have a stageand there is a movieClip instance called "obiekt" in it. Inside "obiekt" movieClip there are two other clips. One instance is called "z1" and another one is called "z2".
    Presume I have a event listener in "z2" what in case of mouse rollover calls a function what is supposed to set "z1" movieClip 'visible' property to true.
    But why the hell when I code:
    root.obiekt.z1.visible = true;
    I get this error:
    1119: Access of possibly undefined property obiekt through a reference with static type flash.display:DisplayObject.
    Jesus - what's the hell - scripting a simplest thing in AS3 requires definig some bloody classes, extending other, importing whatever packages... Only to accesss a movieclip on the stage!!! If I were to do the thing this way I would rather learn C++ not Flash. Flash was supposed to simplify multimedia not making it worse!
    Can anybody help me here? It's really urgent !!!
    Rgs,
    Ziggi

    Look into event bubbling.
    I posted an example in this thread yesterday:
    http://forums.adobe.com/thread/433959?tstart=0
    http://muzakdeezign.com/cs4/Surrey-florist-gallery3.fla
    Best is to forget about root and trying to access objects in a "parent".
    It's all about event dispatching.

  • Accessing swf metadata rdf:Description etc

    Hi Guys, anyone found a way for a swf to access it's own xmp and rdf metadata.
    Essentially what i'm after is a way to embed a variable in a swf without having to decompile and recompile it, setting one of the preused metadata tags to that and then reading it would solve that problem.
    Any help is much appreciated

    Unfortunatley not, i'm trying to automate a dynamic content system, much like the old macromedia generator, where we have one swf file with one internal variable changed.

Maybe you are looking for

  • Hide a colum in bex report

    Hi All, I have a report with 12 column which is displaying 12 months sales data. Now I want to hide a column which is not haveing any data. please help me Thanks Billy

  • IDVD keeps quiting

    i recently formatted my drive and reinstalled 10.5.7, now i dont recall if iDVD worked after the reinstall or not but i today put the bonus themes from the disk on.. now every time that i try to load iDVD it just keeps quiting unexpectedly. Any idea

  • Commerce service pack 1

    Hi all, I've installed the Commerce Server (finally!), and I have sp1 (WebLogicCommerceServer311sp1.zip), but there are no directions to where and how to install it! Do you know where I need to put the jar file? what changes are needed in the bat fil

  • For information - sharing between iPhoto 6 and IPhoto 08

    Just tried (I've held off installing iLife 08 on the Macbook as I'm not convinced about the stability of all components yet!) this. iPhoto6 see the files shared from iPhoto 08 - as Events are not supported in 6 you just get the thumbnails for the who

  • Classes missing from autocomplete

    I'm using Eclipse with the Flex Plug-in. One of the Flex projects in my workspace suddenly no longer displays everything that should appear when the autocomplete window pops up. For example if I want to add a VBox into an mxml file and I type the "<m