ActionScript 3.0 :: _root, _level... Not Working In Loaded File?

Feb 5, 2009

I have loaded as2 swf in as3 using Loader object. Loading is done fine, but the problem is that the as2 swf uses stuff like _root, _level1.. etc. that doesn't work in as3. So is there any way by which I can make as2 swf work properly inside as2? I have bought some readymade as2 swf and need to use them here. I dont have the as2 fla so can't make any changes in them...

View 9 Replies


Similar Posts:


ActionScript 2.0 :: MC With LoadVariablesNum Don't Work If I Loaded Into Other _level?

Jan 23, 2005

why my MC actionscript with loadVariablesNum("submit.php", 0, "POST"); don't wanna work if I loaded into other _level...

If i don't loaded it work well... but not useful

View 5 Replies

ActionScript 2.0 :: If(_root.currentframe Not Working?

Feb 10, 2009

I can't seem to get... if(_root.currentframe to work. It just doesn't seem to recongnise what the _root frame is and won't goto the desired frame.I've attached a simple flash example which is very basic with a button inside a mc that asks the _root for the frame and if it's on frame 1 then should goto frame 5 - but it doesn't work. I've added a trace and that's returning the correct frame so it knows what the frame is.The actionscript on the button is..

on(release){
trace(_root._currentframe);
if(_root.currentframe == 1){

[code]...

View 3 Replies

ActionScript 3.0 :: _root.MyVar Not Working ?

Feb 1, 2010

if i have embeded swf like myswf.swf?myVar=test.txt ,i get by _root.myVar (test.txt)how can i get this parameter in AS3? I have searched google but no success

View 3 Replies

ActionScript 2.0 :: If (_root._currentframe != 6){ Is Not Working?

Jan 8, 2007

this code should work, but doesn't. Am I missing something? I'm simply trying to disable the button "cardSearchBtn" when the root timeline enters frame 6 (along with two other play actions).

Code:
if (_root._currentframe != 6){
cardSearchBtn.enabled = true;[code].........

View 2 Replies

ActionScript 2.0 :: Referencing Something In _root Not Working

Nov 13, 2007

I have a class 'resizingObject', with a method 'addFunction()', which is instantiated in _root as 'resizer' (im certain of this - ive checked in the debug - variables list)

I then have another class, 'layerObject', that i want to be able to call the 'addFunction()' method - so inside the layerObject i tried _root.resizer.addFunction(), _level0.resizer.addFunction() and all manner of other business but to no avail...even an attempt to trace _root.resizer returns undefined.

why cant i acces the resizer instance of the resizingObject?

View 1 Replies

ActionScript 2.0 :: _root.onLoad Not Working In Firefox?

Mar 4, 2005

I have a very, very simple thing in Flash that just will NOT work in Firefox and it's driving me nuts. On the very first frame of the root, I have the following code:

Code:
this.onLoad = function() {
_root.createTextField("test1_txt", 10000, 0, 0, 300, 100);
test1_txt.text = "WORK!!!";

[Code]....

This works all right but again, it's a hack, and I'd rather avoid using a hack like this.

View 1 Replies

ActionScript 3.0 :: CurrentLabel Not Working On Loaded .SWF File?

Mar 18, 2012

I am trying to get this to work for ages but doesnt seem to work out quite well this is my code:

[Code]...

View 1 Replies

ActionScript 2.0 :: OnClipEvent + _root = Sliding Pages Not Working

Feb 2, 2009

I'm having a tough time with a page sliding clip, and not sure what to do.

I've got a movieClip with a page sliding effect that I found here at Flash Kit. It's perfect for what I need, however the effect will only work in that movieClip. Once you try to load that movieClip from anywhere else, the sliding no longer works.

Here's the code that's on the image clip:

Code:
onClipEvent (load) {
_x = 0;
_y = 0;
spd = 5;

[Code]....

View 1 Replies

ActionScript 3.0 :: XML Data Not Working With Externally Loaded SWF File

Jul 21, 2011

I have successfully loaded XML data into a SWF file and am able to get values from the XML without much problem. The code works. For example my test productimage[1].toString(); is returning back the correct value from the XML file.My issue is when I load this SWF into another, a preloader, the code no longer works? The preloader is working fine and the rest of the SWF file is loaded in succesffully, even the XML data appears to be working when I run a trace i.e. trace(e.target.data.toString()), but for some reason the individual data values such as productimage are no longer being defined??]code]

View 5 Replies

ActionScript 3.0 :: XML Data Not Working With Externally Loaded SWF File?

Jul 21, 2011

I have successfully loaded XML data into a SWF file and am able to get values from the XML without much problem. The code works. For example my test productimage[1].toString(); is returning back the correct value from the XML file.My issue is when I load this SWF into another, a preloader, the code no longer works? The preloader is working fine and the rest of the SWF file is loaded in succesffully, even the XML data appears to be working when I run a trace i.e. trace(e.target.data.toString()), but for some reason the individual data values such as productimage are no longer being defined???

Code:
var requestXML:URLRequest = new URLRequest("liveshow.xml");
var loader:URLLoader = new URLLoader();

[code].....

View 1 Replies

ActionScript 2.0 :: Usage Of _root Command With Loaded Swf Files?

Feb 20, 2003

i have a problem because i do not understand why one cannot use _root commands when you load a swf file into one other, if you are using loadmovie?!

i think this is kinda logical, but is there an alternative>

View 2 Replies

ActionScript 1/2 :: Textbox Shows Xml Text In Working File But Now When Loaded Into Another SWF

Dec 7, 2010

I have downloaded an xml gallery (as2) as we needed one for an old as2 file. Now I mostly use as3 but thought as I only needed to tweak it there would be no probs. Of course, it rarely works out that way. The problem is, text loaded from the xml file is displayed with its corresponding image. This works fine in the file.When I load the SWF into another SWF however, it all works EXCEPT the text doesn't show at all?? Whoever made the gallery used 'device fonts' in the textbox, I don't know if this has anything to do with it. I tried changing the textbox to dynamic and embedding characters but still nothing.

[Code]...

View 3 Replies

ActionScript 2.0 :: Change The _root.broj And _root.logo Variables Inside The Function?

Jan 14, 2010

In the code below i want to change the _root.broj and _root.logo variables inside the function which returns values from .php file. Inside the function everything works fine and all values are correct but when i trace var broj outside the function it's still 0.

var result_lv:LoadVars = new LoadVars();
var send_lv:LoadVars = new LoadVars();
var broj:Number=0;
var logo = new Array();

[Code].....

View 1 Replies

ActionScript 2.0 :: _root.cargo Are Multipled By 10 And Added To _root.totalscore?

Feb 27, 2003

im lookin to make this so that the points taken from the _root.cargo are multipled by 10 and added to _root.totalscore

[Code]...

View 2 Replies

ActionScript 2.0 :: Loaded Movie Doesn't Execute _root Functions In IE (security Sandbox)?

Apr 23, 2010

I'm having some weirdness with a project that I'm doing in IE. Long story short, I've got a basic shell that loads in external SWFs based on user feedback. Once those SWFs get loaded in, they execute functions from the shell (_root) movie. It works great in Firefox, but immediately breaks (no way) in IE. The movie gets loaded in, but none of the functions run.

I suspect it has something to do with security, because, for a variety of reasons, I have to load the SWFs from their absolute location, rather than their relative location. When I test it locally (but loading the movies from their absolute, live location), everything still works, but I get that damn security warning that reads like this:

[Code]....

View 2 Replies

ActionScript 2.0 :: _root._root[eelmine].nextFrame()?

Sep 14, 2004

if a condition is true, then:_root.(MC with instance name that is the value of "_root.eelmine").nextFrame(); is this correct?_root._root[eelmine].nextFrame();

View 16 Replies

ActionScript 2.0 :: _root - Load Swf Into Another With "loadmovie" With An Empty MC The Pages Stop Working

Nov 14, 2004

Im new in actionsript and I have a problem with _root. I have a swf. with two MC en the main stage: Mc_menu and Mc_pages. The Mc_menu has several buttons with the code "_root.pages=2" which moves the different pages that are in the Mc_pages. If I publish the fla. it works perfectly. Now, when I wanted to load this swf into another with "loadmovie" with an empty MC the pages stop working... I guess is because of the rutes, but i don�t know how to refer them correctly. What I have right now is: in the main stage an empty MC and a button with the code:

[Code]...

View 2 Replies

ActionScript 1/2 :: OnLoad Working At _root Level But Not At Mc_target Level?

Aug 26, 2010

I have two layers in my FLA both with empty movie clips as follows:In mc_Empty1, I attach a faded background movieclip as I wait for mc_Empty2 to load a SWF.  Once the SWF is loaded into mc_Empty2, I want to remove the faded background movieclip from mc_Empty1.  When I load the SWF from the main timeline, the onLoad() function works and removes the faded background from mc_Empty1.  However, when I load the SWF from mc_target, the SWF loads, but the onLoad() function does not.  Here's my AS2 code:
 
//Loading SWF from main timeline
mc_Empty1.attachMovie("mcFadedBg", "mc_FadedBg", 1);
mc_Empty2.loadMovie("My.swf");mc_Empty2.onLoad = function():Void{    trace("loaded"); //This works    removeMovieClip(mc_Empty1.mc_FadedBg); //This works}

[code]....
 
I know I'm targeting properly because the SWF loads as it should, but the onLoad() function does not. 

View 3 Replies

ActionScript 1/2 :: Referencing _root.Button  From A Movie Loaded Inside Another Movie?

Oct 18, 2009

MainMove.swf is doing a loadmovie of SecondMovie.swfThe Button that loads SecondMovie.swf also disables other buttons in MainMovie.swfon (release) {  _root.intro_btn.enabled = flase;  loadMovieNum("SecondMovie.swf", 2);How do I Re enabled the Buttons in MainMovie.swf from a Button within SecondMovie.swf???

View 4 Replies

ActionScript 3.0 :: No Longer Move The "_root" By Changing The _x And _y Positions Of The _root?

Jan 26, 2009

I just recently began migrating from AS2 to AS3, and I have of course realized that I can no longer move the "_root" by changing the _x and _y positions of the _root (which no longer exists in AS3). How can I do this in AS3 (specifying _x, _y, _z possibly of the "_root")?

View 2 Replies

ActionScript 2.0 :: Putting _level In A For To Do Loop?

Apr 28, 2010

Loading stuff in levels ( MovieClipLoader.loadClip(picOrSwf, 1); ) and want a -for to do- loop to make them all _visible = false; but can't get it to workfor (i=0; i<total; i++) { _root[_level+i]._visible = false; } is the closest I got. (_root[_level+1]._visible = false; DOES work, but is no good of course).Let me know if this outlines my problem goo

View 4 Replies

ActionScript 2.0 :: Clicking Buttons On Different _level

May 4, 2010

Loading Images in _levels via loadClip. Now i want 2 buttons on TOP of the Images. So first tried attachMovie _level 200. Did't work (don't ask me why since all logic says it should. but I'm guessing a difference in loading between loadClip & loadMovie). Now made 2 swf files with just the buttons and load via loadClip. Works fine BUT... now I can click then. tried stuff like:

Code:
_level200.button_btn.onRelease,
_level200[button_btn].onRelease, _level200["button_btn"].onRelease, _root[_level200["button_btn"]].onRelease
You get the picture. Any solution to this?

View 9 Replies

ActionScript 2.0 :: Controlling Sound In A Different _level

Apr 8, 2005

I have a loaded SWF file in _level1 that has audio in the timeline. I am trying to control the volume of this loaded SWF with a 'mute' button in the main SWF file. On the first frame I'm using the code:

my_sound = new Sound(_level1);
and then on the button script I have:
mute_btn.onPress = function(){
my_sound.setVolue(0);//mute volume
}

but it's not working. Is the new Sound(_level1) not valid?

View 1 Replies

ActionScript 2.0 :: Load Swf In Center Of _Level?

Aug 15, 2006

how I can center a swf, when I load it into a _level?

View 1 Replies

ActionScript 2.0 :: Controlling Sound In A Different _level?

Apr 8, 2005

I have a loaded SWF file in _level1 that has audio in the timeline. I am trying to control the volume of this loaded SWF with a 'mute' button in the main SWF file. On the first frame I'm using the code:

my_sound = new Sound(_level1);
and then on the button script I have:
mute_btn.onPress = function(){
my_sound.setVolue(0);//mute volume
}

but it's not working. Is the new Sound(_level1) not valid?

View 1 Replies

ActionScript 2.0 :: Mousewheel Within An Embedded Flash _level?

Feb 21, 2011

However I am using embedded .swf files, and the scrollable image I want to control is on _level10 (within a master file _level0). I am decent with actionscript and based on tests with the example file, I know the code works. BUT my problem is getting it to function within a different flash level. I'm about 99% sure it isn't working because the code is looking for my movieclips or the scroll function on the main timeline and not that of _level10, but I can't figure out where the code I need to change is. Its driving me crazy.Here's the code (from the above link). This goes into the main timeline, where "area1" is the movieclip you hover over to enable the mousewheel and "mc1" is the mc that is moved by the mousewheel:

Actionscript Code:
// IMPORT import FlashCommon.MouseControl;import mx.utils.Delegate;Stage.scaleMode = "noScale";// ADD SCROLL FOR AREAS - addScroll(id, mc, function)//// adding scroll

[code].....

View 2 Replies

ActionScript 1/2 :: Load External Swf Into A Specific _level

Sep 15, 2009

I am loading an external swf into the mc 'image' using: image.loadMovieNum("portfolio/100_design/1.swf", 1);

Every time a new image loads, I want it to load the level above, ie: image.loadMovieNum("portfolio/100_design/1.swf", 2); Is there a way this can be done dynamically. For example, "current level + 1"

View 5 Replies

ActionScript 3.0 :: Loaded Swfs Not Working When Loaded Through Xml?

Jun 10, 2010

I have a "photo" gallery that loads numerous SWFs through xml, one by one on click. All works fine. All my SWF work fine stand alone. But when I load them into the player, many swf dont work properly.in example, I have textinput textfields in many of the swfs, which work fine on their own but not when loaded into the player. Then I have a word search game that works fine when alone, not when in player. I can see there is something as my mouse cursor changes into the "button finger", but nothing visual.

All drag and drop assigments work fine etc. I have no idea whats up. I have receantly switched to as3 and in as2 there was _lockroot declaration that solved similar problems, but now in as3 (where it supposedly should be automatic) it doesnt work. As it seems that it cannot recognise it own stage value, or selection_focus when loadedinside another swf through xml.Using cs4, as3.

View 4 Replies

ActionScript 2.0 :: Create An Array Of Object And Store The _level

Aug 23, 2010

I want to create an array of object so that I can store the _level I want to load image at specified level and and to keep track of levels in an array so that when any new image will be loaded I can get location of previously loaded image and place the new image before the last image

Code:
loadMovieNum(_global.myXML.childNodes[0].childNodes[3].childNodes[5].childNodes[0].attributes.path, 178);
_root.mcTray._alpha = 100;
_level178._x = 20;
_level178._y = 620;

View 1 Replies







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