ActionScript 3.0 :: Problems Targeting A Loaded Swf

Apr 18, 2010

When you click the about button on my site, I am using this function to load in an external swf, about.swf. When I click on another nav button, I want to communicate with the about.swf and call a function within that swf called bailout(). But how do I target it? Nothing I try works. I've messed with getChildAt but don't know how it works.
Would it be ..... theholder.aboutLoad.bailout()??? That doesn't work. How do i target the function within the about.swf file?

[Code]...

View 3 Replies


Similar Posts:


ActionScript 3.0 :: Targeting A Loaded Swf

Nov 11, 2009

1. I'm loading an external swf onto my main swf.
2. Then I'm tweening an object which is separate to the loaded swf.
3. When the tween has completed I'm calling a function to make the loaded swf gotoAndPlay(2);

[Code]....

View 8 Replies

ActionScript 2.0 :: Targeting Loaded .swf?

May 1, 2003

this code is working to load and position the external swf, but it won't gotoAndPlay to the frame inside the external swf--what am doing wrong here?

PHP Code:

bio.onPress=function()[code]......

View 3 Replies

ActionScript 1/2 :: Targeting Swf Loaded With LoadClip()?

Feb 7, 2010

Basically, I have a main .swf, into which I am loading another .swf using loadClip(), on the click of a button. It loads into an empty movie clip on the timeline of the main .swf called container_mc. So far so good, this works.
 
The problem comes when I am trying to control a movie clip that lives on the timeline of the external .swf. This clip has the instance name test_mc, and I'm trying to control it using the reference _level0.container_mc.test_mc. I have also tried just plain old container_mc.test_mc.
 
Neither of these work, though when I apply a trace to test_mc with Actionscript on the timeline of the external swf (test_mc.onRelease = function () { trace(this); }), it returns the path _level0.container_mc.test_mc (when clicked on after being loaded into the main movie, obviously).

View 5 Replies

ActionScript 1/2 :: Targeting The Timeline Of A Loaded Swf - AS2

Feb 9, 2010

I'm loading an external swf into a project and I want to be able to start and stop the loaded swfs timeline at will.... I'm loading swf into an MC: loadMovie("myFile.swf", swfHolder_mc);

View 1 Replies

ActionScript 2.0 :: Targeting Swf Loaded With LoadClip()?

Feb 21, 2010

I have a main .swf, into which I am loading another .swf using loadClip(), on the click of a button. It loads into an empty movie clip on the timeline of the main .swf called container_mc. So far so good, this works.The problem comes when I am trying to control a movie clip instance that lives on the timeline of the external .swf. This clip has the instance name test_mc, and I'm trying to control it using the reference _level0.container_mc.test_mc. I have also tried just plain old container_mc.test_mc.

Neither of these work, though when I apply a trace to test_mc on the timeline of the external swf (test_mc.onRelease = function () { trace(this); }), it returns the path _level0.container_mc.test_mc (when clicked on after being loaded into the main movie, obviously). I've attached a couple of files demonstrating the problem I'm having. It seems to me that the problem is probably something a little amiss with my code,

View 1 Replies

ActionScript 3.0 :: Targeting Mc's Within Externally Loaded .swf?

May 26, 2009

I have an .swf which I call into a loader identified as "level_". I want to do a hitTest between a MovieClip in the main file and a MovieClip on level_'s Stage. In AS 2.0, the path would've been: this.level_.wall0

I get this error: 1119: Access of possibly undefined property wall through a reference with static type flash.display:Loader.

Tracing the .numChildren of the loaded .swf reveals that it has zero children. Within that .swf wall0 and the other MovieClips are instances dragged from the Library and given names. So what am I missing? Is the problem that wall0 hasn't been properly added as a child in the externally loaded .swf? Or is it something I need to resolve in the main .fla?

View 2 Replies

ActionScript 2.0 :: Targeting Swf Loaded With LoadClip()

Feb 21, 2010

I'm having a really weird problem with loadClip(), using Actionscript 2.0. Basically, I have a main .swf, into which I am loading another .swf using loadClip(), on the click of a button. It loads into an empty movie clip on the timeline of the main .swf called container_mc. So far so good, this works.

The problem comes when I am trying to control a movie clip instance that lives on the timeline of the external .swf. This clip has the instance name test_mc, and I'm trying to control it using the reference _level0.container_mc.test_mc. I have also tried just plain old container_mc.test_mc.

Neither of these work, though when I apply a trace to test_mc on the timeline of the external swf (test_mc.onRelease = function () { trace(this); }), it returns the path _level0.container_mc.test_mc (when clicked on after being loaded into the main movie, obviously).

I've attached a couple of files demonstrating the problem I'm having. It seems to me that the problem is probably something a little amiss with my code, as in theory I'm pretty sure what I'm trying to do is perfectly possible.

View 1 Replies

ActionScript 2.0 :: Absolute Targeting In A Loaded Swf?

Sep 15, 2004

i'm in the process of building a movie that is to be loaded and played into another main swf. the targeting (which is multi-level) works fine when the movie is played by itself but when it's loaded and played in the main swf some of the targeting doesn't work. i've tried using _parent. and stuff like that but it's not working. any ideas? can someone point me in the right direction? the frustrating thing is that some of the targeting does work.

View 1 Replies

ActionScript 2.0 :: Targeting Dynamically Loaded Swfs?

Mar 21, 2006

Having trouble targeting movieclips in a dynamically loaded swf. (Flash 8, Actionscript 2).I have a swf file, which contains a set of duplicated movieclips, that I am loading into another swf file (using the movieClipLoader() class), basically like this: "swfA" is loading into "swfB", and I have clips 1, 2, and 3, inside "swfA."I don't seem to be able to mouseover and click clips 1, 2, and 3, when "swfA" is loaded into "swfB". But when I run "swfA" on it's own, the clips are active and clickable.I've tried setting "this._lockroot = true;" at the top of "swfA", and tha in the duplicating script, but still no luck targeting the clips.I usually execute the duplicating script on the main swf (swfB), but I wanted to contain everything in a swf, thinking it might be simpler. But the targeting problem has me scratching my head.

View 1 Replies

ActionScript 2.0 :: Targeting Loaded Object / Movie

Jun 29, 2007

I am doing a dynamically loading gallery by way of xml, now, i have the loading of the images going to where flash sizes them and puts them down as thumbs, all i want to do is when the user clicks on the thumb that already loaded image gets duplicated into the main area full size.... for the life of me i can't figure it out, it seems like it would be simple enough but i have been pulling my hair out for the longest..... by the way the publish settings are actionscript 2.0 with fp8.

View 5 Replies

ActionScript 3.0 :: Targeting A Button Inside Dynamically Loaded SWF

Jun 4, 2010

I have a main.swf which loads a sub.swf. Inside the sub.swf is a button instance (myBtn). How do I access myBtn from main.swf timeline?

View 7 Replies

Actionscript 3.0 :: Targeting A Movie Clip Inside A Loaded Swf?

Jun 10, 2009

I loaded this "slider" swf into a "sliderHolder" on my index swf file. inside that loaded swf there's a movice clip called icon_mc. I'm trying to target it and make it go to a specific y position within that loaded swf on a MouseEvent inside the index.swf. I can't seem to make it work.I triedI have traced sliderHolder and it says it's empty.I have traced sliderLoader and it gives a Loader.So how do I access the movieClip if I just have those two as references?Here's what I have and want to do in code:

Code: Select all
var sliderLoader:Loader = new Loader();
sliderLoader.load( new URLRequest("sliding/ImageBar.swf"));

[code].....

View 1 Replies

ActionScript 2.0 :: Targeting A Timeline In An Loaded Movie Clip?

May 27, 2005

The swf successfully loads where I want it to, but I'm having trouble moving the new movie clip to a specific keyframe in the timeline.

Code:
on (release) {
_parent.productImage.loadMovie("./flash/BT_Closeup.swf");
_parent.productImage.gotoAndStop("set2");
}

View 1 Replies

ActionScript 2.0 :: Targeting A Mc With Within A Mc?

Mar 2, 2006

I have made a navigation that is a movieclip, now within the movieclip are 6 movieclips that are the "buttons" of the navigation. This is then placed on the maintimeline as the movies navigation. When one of the "buttons" is pressed i want it to go to a specific point on one of the 6 movieclip "buttons" timeline. This is the code that I have used before on the maintime line to target a movieclip there... but never a mc within an mc. First, would I still place this code on the maintime? or within the mc that the 6 mc buttons are placed? Second how would I target the nav buttons mc's?

stop();
but1.onRelease = function() {
this.gotoAndStop(9);

[Code]....

View 2 Replies

ActionScript 2.0 :: F8 Targeting Gets Lost

Jan 15, 2009

I've got a dynamic textfield clip which is placed twice on the stage. It also includes a button. Funny thing is, the first trace works (tracing its _y value: 0 for clip 1 and 200 for duplicate clip 2). When I press the down button of both clips however it traces undefined though it's the same line. How does onPress mess up the targetting of both clips? [code]

View 6 Replies

Targeting Label In External SWF?

Feb 12, 2010

I have 2 SWF (swf1 and swf2). I want to load swf 2 into 1, but getting it start on a label or a particular frame.I use this to load SWF 2

Code:

on(release){
loadMovie("movie2.swf",0);
}

How do i target it to start from a label in a scene from movie2.swf?

View 3 Replies

ActionScript 3.0 :: Targeting MC Already Placed On Stage?

Apr 28, 2011

I'm trying to target an MC that is already placed on the stage (as opposed to adding it from the library).

But I get this error:

Quote:

TypeError: Error #1009: Cannot access a property or method of a null object reference.
at com::Test()
at objects_fla::MainTimeline/frame1()

[Code]....

View 5 Replies

ActionScript 3.0 :: Targeting An Instance Of A Mc?

May 27, 2009

With AS2 I u sed to do  createEmptyMovieClip("name"+i, to create multiple instances of an mc. I ocuuld then target these individual instances

[Code]...

View 4 Replies

ActionScript 3.0 :: Targeting An Event From A Different MC?

Feb 4, 2011

I made a  play/pause button for this project I'm working on (basically a slideshow with a different movieclips on each frame) and I have managed to get it to  target either the main timeline or a nested MC. The problem is with the  code I have is that the button will only work for one MC at a time. This  means I will need a separate play/pause button for each individual  slide. Is there some way to make a button that globally starts and stops  any MC without effecting the main timeline?
 
Here is the code I am using now:
 
stop(); 
pause_btn.addEventListener(MouseEvent.CLICK, stopplaying);function stopplaying(event:MouseEvent):void {    MovieClip(parent).green.stop();    gotoAndStop(2);}
 
Ned proposed adding an event at the beginning of each movie clip and programming the play/pause button to work that way. My problem (after spending a lot of time with it) is that I can't get my play/pause button (a MC itself) to target the event in a separate MC. 
 
This is my event placed on the first frame of my movie clip:
 
dispatchEvent(new Event("imHere"));
  
This is the code I have in the play/pause button that doesn't work:
 
stop(); 
pause_btn.addEventListener(MouseEvent.CLICK, stopplaying);function stopplaying(event:MouseEvent):void {    gotoAndStop(2);}

[Code]....

View 8 Replies

ActionScript 2.0 :: Targeting SWF From Another One In ECard

Jul 31, 2009

I am building an ecard, and I created two swfs. The first swf is the actual ecard, with a dynamic text box that is going to display the message. The second swf is where you would actually type in the information, such as name, email, and message. Is it possible for two swfs to "talk" to each other inside an html document? Also, I am not quite sure how to send the card to someone's email. I am assuming that when you hit SEND it reads the input box with that email, but not sure how that works.

View 1 Replies

Actionscript 3.0 :: Targeting A Mc In A Different Timeline?

Dec 30, 2009

I have a main.fla which has 3 movieclips inside it. All 3 mc's have timelines that run 40 frames. The main.fla timeline has each mc instance on a frame.

mc_1 is on frame 1
mc_2 is on frame 40
mc_3 is on frame 81

as the main timeline plays the clips each one fades to the other.

I need to know how to target this scenerio

after mc_3 plays I need to have a goToAndplay (frame) set up so the animation inside mc_1 starts playing (frame 20) of mc_1.

I know how to do off a button

but there is no buttons, the action needs to happen when the playhead reaches the last frame of the main timeline in main.fla

View 2 Replies

ActionScript 2.0 :: Targeting External .swf's?

Oct 5, 2004

targeting external .swf's.I am trying to load external movies to a main movie in a branched manner (i.e. root -> first movie has buttons to load second -> second movie has buttons to load third) in specific areas on the main movie.

In this simple flash im trying to get the main-button to load onto the main movie. Once it loads, a button appears and replaces the black square. When you click on it a series of other buttons appear on the side and replace the red square. Once those buttons appear, when one clicks one of them a small movie loads into the blue square and replaces it.

View 3 Replies

ActionScript 2.0 :: Targeting A Nested MC?

Jul 13, 2006

I am creating a drop down menu and having problems adding problems to the nested MCs. I have all the actions on the root timeline and I have a one Main_MC which holds several Sub_MC's.I have the Main MC animated fine but I can't find how to control the Sub-MC's.Here is a sample of my code and I have tried _root. and this. and show below but I can't get it to work.

//main MC
Main_MC.onRollOver = over;
Main_MC.onRollOut = out;[code].....

View 9 Replies

ActionScript 2.0 :: Targeting Function Within MC?

Jul 14, 2006

I am trying to start and stop an animation from outside of the main timeline. I have written the functions inside the movie to start and stop the animation and they work fine when called from within the movieclip but when I call them from the maim timeline I get nothing. I have checked the targeting is correct and can't think what this is

View 6 Replies

ActionScript 2.0 :: Targeting A Fame?

Jun 19, 2003

i have three MC's 1,2,3 and a button for each of them, on pressing each button it makes the appropriate MC play half way then stop at a frame with a stop action. BUT what i want is to use a if statement something like this

script is on MC1 button

tell MC1 to play ();
if MC2 is at frame xx
tell it to play ();

eles do nothing

View 4 Replies

ActionScript 3.0 :: Targeting A Button Within A MC From Another MC?

Jan 5, 2010

I know what the error 1061 means, but have no idea how to fix it. I've tried to correct it a million & one ways...

Code:
1061: Call to a possibly undefined method getChildByName through a reference with static type flash.display:DisplayObject.

I'm trying to target a button named 'mcTargetButton' (a SimpleButton) that's inside a movie clip called 'mcTargetParent' from a movie clip called 'mcCallFromThisClip'.

Both clips are on the main timeline. Note, I am using a document class... if I trace (this.parent) from 'mcCallFromThisClip' it prints the name of the document class.

[Code].....

how hard should it be to reach a button from a different movie clip?

View 1 Replies

ActionScript 3.0 :: Geo Targeting In Flash?

Feb 23, 2010

Something has come up where we may need to do some geo targeting to deliver different content to a video player based on the client's (as in end-user) location. Basically, we would want to control the delivery based on country. This sounds like a huge, deep topic that I can't even begin to address. Anyone have any thoughts or experience doing this sort of thing with Flash content?

The swf may need to sit on a server we have no back-end access to, so ideally it would be a solution that doesn't require PHP or any other sort of back end...but I'm not sure if that's possible.

View 2 Replies

ActionScript 3.0 :: Targeting MC Inside Of MC?

Mar 12, 2010

I have 10 MC that are generated inside of a for loop. Each MC got another MC inside of it that is already sitting on the stage and has it's own instance ame applied! After that I put them inside of a MC container, that I also add dinamicly through the addChild method! But I have one issue when I want to change the position of the child MC(one that is sitting on the stage), through targetting to it's instanceName! The code I use:

Code:
var box1_mc:Box1 = new Box1();
var ball1_mc:Ball1;
var balls:Array = new Array();

[Code].....

View 1 Replies

ActionScript 2.0 :: Targeting Objects Between Swf's?

Jan 28, 2011

So i have multiple swf's that are within a stage. The main swf (index.swf) has a menu and once clicked it makes another swf to display. A common issue i'm having is that for the other swf's. I have animations which work within that swf but when i run from index they don't work.I know this is because of the targeting of the object but how do make this work?ample on 5.swf i have a button that has an action, when a mouse cursor goes over it a photo fades in and out on it, and that works when i run 5.swf

View 9 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved