ActionScript 2.0 :: Check Variables In MyPictures.onLoad, The Variables Are Always The Same?

Aug 5, 2004

I have 2 loadVars - myVars, myPictures

basically i have defined their onLoad functions

so in myVars, i call for

Code:
myPictures.load("http://www.fakedevil.com/lurgee/pictures2.php?id="+this._parent.link2.text+"&time=" add getTimer(), "");

pictures2.php is working cos I just check so by rite the variables loaded should change.. but somehow each time I check those variables in myPictures.onLoad, the variables are always the same.

View 5 Replies


Similar Posts:


ActionScript 1/2 :: Xml.onLoad Variables Undefined Outside?

Aug 25, 2009

I've been searching this problem for a while and have tried a number of solutions found on google but nothing has worked so far. I'm sure this is a common problem, but due to my lack of flash knowledge I can't logically work through it as I'm used to windows form development, it makes sense to me that the function could access the variables I have defined but they dissapear after the .onLoad event. Does anyone know the common solution to this problem? I want to be able to pass the xml details into the local variables so I can pass on the details into a dynamic text field when movies are hovered over etc.

[Code]...

View 3 Replies

ActionScript 2.0 :: Passing Variables Out Of XML OnLoad

Nov 7, 2005

I'm trying to pass a variable out of the 'XML.onLoad = function() {', but the variable keeps coming up undefined. This is what my actionscipt looks like:
Code:
XMLData.onLoad = function() {
_global.variable = ......
} trace(variable)

View 6 Replies

ActionScript 1/2 :: Xml.onLoad Variables Undefined Outside Function?

Aug 25, 2009

I've been searching this problem for a while and have tried a number of solutions found on google but nothing has worked so far. I'm sure this is a common problem, but due to my lack of flash knowledge I can't logically work through it as I'm used to windows form development, it makes sense to me that the function could access the variables I have defined but they dissapear after the .onLoad event. Does anyone know the common solution to this problem? I want to be able to pass the xml details into the local variables so I can pass on the details into a dynamic text field when movies are hovered over etc

var myXML:XML = new XML();
myXML.ignoreWhite=true;
var nav1Text:String;

[code].....

View 3 Replies

ActionScript 2.0 :: [fmx] Keep Variables Past The Onload Call?

Jan 20, 2004

I've created a multi-framed flash file that's calling multiple variables from an external php (text) file. I'm using an onload command to do this and for some reason the variables seem to "disappear" once I leave the first frame (where the onload and load commands are)I'm figuring that my problem has to do with 'variables scope'. I've read the article on this site but I don't know actionscript well enough to proceed.I ultimately want to do away with using multiple frames by using multidemsional arrays and for...next loops, but this is what I have to work with (for now). I'm going crazy trying to get THIS to work.

[AS]
// ##################################
// FRAME 1

[code]......

View 4 Replies

ActionScript 2.0 :: Retain Variables From OnLoad Event?

Sep 26, 2004

Is it possible to retain variable information after exiting an onLoad event?I have a variable declared outside the onLoad event which a function called from within the onLoad event populates. The problem is, after leaving the onLoad event the variable gets cleared

View 1 Replies

ActionScript 2.0 :: Can't Get XML List To Scroll Because The Variables Won't Travel Outside The Xml.onLoad Process?

Jan 29, 2008

i have a list cranked out from an XML file (movieclips attached to empty clip). currently it loads as the SWF launches. i can't get it to scroll because the variables won't travel outside the xml.onLoad process. what i'm wondering is once i bury this process into a button activated function, will i be able to access the list's properties? (sweet Buddha i hope that made sense...)

it seems the fundamental principle i'm struggling with is var/scope issues: how and where variables/properies can travel. i can't seem to find an explanation that makes sense from a C++ perspective. everytime i think i get it, something like this kicks me in the nuts. for those who want to dig, i'm using Kirupa's custom scrollbar modified (seemingly unsuccessfully) to my own setup. if you can recommend a different one more suited to this sort of thing, i'm open to it. if this doesn't make sense, i can attach the FLA but its a bit of a read and i'm in need of an answer before Thursday. methinks once this project is done, i'm going to hire someone for a week to fill in the gaps in my knowledge!

View 4 Replies

ActionScript 2.0 :: Assign Multiple Variables, And Check Multiple Variables?

Oct 6, 2011

I just want to know if there is a way to assign multiple variables, and if there is a way to check multiple variables.

I want to be able to assign variables to false and then check if all the variables are false.

View 1 Replies

ActionScript 1/2 :: Check TWO Variables In PHP File?

Aug 9, 2010

We have a FLASH website that uses PHP to authenticate users.

We have recently been asked to implement TWO variables as we used to only have one.[code]...

View 3 Replies

ActionScript 2.0 :: Check The Value Of 5 Different Variables At The Same Time?

Oct 26, 2005

I wanted to check the value of 5 different variables at the same time.

Based on the value each of variable I wanted to make 5 corresponding movie clips do something.

There has gotta be a better way to do this rather than me using a bunch of if else statements.

View 4 Replies

ActionScript 2.0 :: Check To See If All Variables Are Filled In?

May 26, 2004

I have a form that uses PHP to check to see if all variables are filled in. I have a button with

on (release) {
formcheck();
}

that checks the formcheck function and then sends the form or gives a popup that tells what part of the form needs to be filled in.

My problem is that I have a movie that I'd loike to act as a button. I've done this before with any other command (gotoAndPlay, getURL, etc), but the

on (release) {
formcheck();
}

does not work with a mc button, only with a regular button. Does anyone know a way around this, or why it does not work?

View 4 Replies

ActionScript 2.0 :: Check Which Variable Has A Certain Value Then Return Variables Name?

Jan 22, 2009

First of all sorry im not very familiar with the flash lingo, im still new to all this actionscript stuff

ok so i wrote this on a frame in the timeline[code]...

now i need to check which one from all these has a value of zero. then when it finds it i need it to tell me which one it is (s1x or s2x or s3x) so i can do stuff with it.

View 4 Replies

ActionScript 2.0 :: Check If Variables Values Are Defined?

Aug 29, 2005

it's not working. why not?

[Code]....

View 8 Replies

ActionScript 2.0 :: Check Many Different Variables In Many Different MC's Without A Billion If/else Statements?

Sep 17, 2005

Is it possible to check many different variables in many different MC's without a billion if/else statements?

View 2 Replies

Actionscript :: Flash Check Values Of Variables With Flex SDK?

Aug 31, 2011

I use Flex SDK in command line to develop a flash.But trace() doesn't work with Flex SDK.Is there another good way to check values of variables?

View 2 Replies

ActionScript 2.0 :: Run A Check On Dynamic Text To See If Matching Variables

Jul 23, 2011

trying to make a yahtzee game but cant get it to score the 3 and 4 of a kind. I have dynamic text boxes that convert the dice to a number for scoring called result1, result2, ... How do I test to see if 3 of them match or 4 for the 4 of a kind and add the text boxes if 3 numbers match. I have a button that will start the function called score_3kind.

View 9 Replies

ActionScript 2.0 :: Implement Variables To Check State Of MovieClip

Aug 12, 2003

Any best way to script several MCs (acting as buttons) so that on release(), the alphas on the others tween to 20. When you go to click one of the dimmed button, its alpha should tween back to 100 and the previous one that had the full alpha should now fade to 20. Logically, I know I need to somehow implement a variable to check the state of the MC and an if statement to script the actual alpha tweens but I'm confused as how to actually implement it. Where to put it etc.

View 14 Replies

AS3 :: Debugging - Debug Only Project In Flex - Can't Use Trace Or Check Variables?

Aug 7, 2010

I am trying to build a AS3 only project in Flex....I have tried debug mode, but seems like it takes so long to compile....I can't use trace or check variables...Are there anyway to do debug??

View 1 Replies

ActionScript 2.0 :: Defining Variables - Unique To Load SWFs Instead Of Declaring All The Variables

Mar 21, 2012

I have an empty SWF that's sole purpose is to call loadMovieNum and start the project. Each loaded movie has a few variables defined within them - unique to those loaded SWFs. Instead of declaring all the variables in each SWF can I declare all of them in one place, in the first frame of the empty loader it all starts from? I'm thinking I can then declare a variable which each loaded movie can increment as needed for me.

View 2 Replies

ActionScript 3.0 :: Variables True/false Custom Variables Work In Flash?

Aug 20, 2008

How do variables true/false custom variables work in flash?

For example, what I want to do is create a simple true=false variable that I can call on an if statement later.

For example:

Code:
Var1 = true;
if (!Var1)
{

[Code]....

I noticed that neither the "Var1 = true;" part or the if(!Var1) part worked in flash.

View 4 Replies

ActionScript 3.0 :: Array Of Variables - Make A Bunch Of Variables From A For Loop

Feb 21, 2009

How can I make a bunch of variables from a for loop. for example for (var i=0; i<total; i++) {var bunch(i);}. that i make a bunch of variables named bunch1, bunch2, bunch3. I keep getting errors. I program and use so many different languages that I dont know if that can be done with AS3. my only other alternative i can think of is to create some sort of event dispatcher object array. but I dont know how to get them all to send events to one listener with there index number.

View 5 Replies

Actionscript 3 :: Changes To Array Of String Variables Doesn't Update The Variables Themselves

Jul 30, 2010

I have a list of strings that I add to an array, then attempt to set those values in a for-loop using data that I read in. The array gets updated, but the values the array contains do not. I also have an array of buttons that I update this same way that works great, but strings don't seem to work the same way. I have tried moving the string array to give it full scope, and still nothing...

public class test extends Sprite
{
// Declare a list of strings
protected var title0:String = undefined;

[Code]....

View 1 Replies

ActionScript 3.0 :: Load Data From Different Variables - The New Variables Come Back As Undefined?

Jun 15, 2010

I'm writing code that takes data from mysql that's processed by a PHP script. It's actually a bit bizarre, at least to me. Anyway, here's some basic AS3 code that's moving toward what I want to do:

var loader:URLLoader = new URLLoader();
var urlRequest:URLRequest=new URLRequest("receive.php");
urlRequest.method=URLRequestMethod.GET;[code]....

For some reason, the statement "trace(evt.target.data);" produces a whole pile of garbled text before the actual stuff that it's supposed to show Because of problem #1, I've had to include a throwaway variable at the beginning, otherwise the first variable I try to pass into AS3 comes back as undefined. This causes errors when I run my flash movie in the IDE, but when I run it from the browser it doesn't seem to have any effect.But this is the strangest thing of all whenever I make any changes to the database (and subsequently try to load data from different variables), the new variables come back as undefined. For example, let's say that I add another entry to the database, and decide to load students 2, 3, and 4 instead of 1, 2, and 3. When I do that, any new data I've added comes back as undefined, even though when I view the PHP output in my browser, it looks just fine.

And now for the REALLY bizarre part: I'll copy that output, paste it into my PHP script as an echo statement, comment everything else out, and my flash movie runs fine. Even though the output from the PHP script is exactly the same, it gives me errors.

View 9 Replies

ActionScript 3.0 :: Array Variables, Variables Not Working Correctly?

Jul 11, 2011

There is a bird, and you control its upwards movement with a key. It has thrust, gravity, it works fine. The problem is I have a bunch of icicles that come at the bird that he is supposed to avoid. I tried this first with math random to use as an x coordinate and than move across the screen, but the icicles had the same x-coordinates sometimes. I tried does not equal(!=) but that doesn't work. I made an array and each number that came out of the array I assigned a different variable. This works fine. I put this variable into the x-coordinate such as mc.x=((n)*60)+480. I did this for five different icicles. All their differnt variables have a different value, and I put them into the same function for each individual video clip, but they still don't go to the right coordinate. Here is the test code just for the initial coordinate of each icicle before it moves...////////////////////////////Quote:

var temp:Array = new Array()
for (var i:int=0;i<8;i++) {
temp.push(i);

[code]......

View 1 Replies

ActionScript 3.0 :: Create Several Variables To Aasign Each One Of Those Variables One Number?

Apr 9, 2011

i am trying to do a loop to create several variables to aasign each one of those variables one number.when i write

[Code]...

View 4 Replies

ActionScript 3.0 :: Load Variables, Remembering Variables

Nov 19, 2008

I am trying to load variables from a text file, and have them available from then onwards in the movie, globally so to speak.

While I can read the variable values in a loader function which executes when the text file is loaded, I don't seem to be able to keep those variables available afterwards.

View 10 Replies

ActionScript 3.0 :: Regular String Variables Vs XML Variables?

Jun 20, 2009

I'm trying to figure out which is more efficient in terms of memory and speed. What I'm doing is having a series of messages loaded to the screen. Is it just faster to write them in string variable or in an XML document which is more versatile in terms of editing and adding on to the document.

View 1 Replies

ActionScript 2.0 :: Append 3 Variables To A Url That Already Has 2 Variables Appended?

Jun 8, 2006

iam trying to append 3 variables to a url that already has 2 variables appended .. iam using the LoadVars -> "send" method but it wont work. it works if i use a url like "form.aspx" but it wont work if i use "form.aspx?var=nun" which is what i need so i can append 3 more variables to that URL.

View 1 Replies

ActionScript 3.0 :: Conditional Check - *Shape Variables Are Still "none"?

Feb 1, 2012

I define this function

function beatsFilledcheck():void
{
if (a1Shape == "none" || a2Shape == "none"[code].....

whenever I run as

beatsFilledcheck();

it sets beatsFilled = true even if all but one a*Shape variables are still "none".cant understand why?

View 7 Replies

ActionScript 1/2 :: Inserting Variables Into Other Variables?

Jun 4, 2010

I have several objects that have similar names, like slot1, slot2, slot3, etc. I also have a function that is supposed to do something to the first object, then the next, then the next, etc each time a button is pressed. Is it possible to insert variables into other variables? So say I have a variable called n that is increased each time the button is pressed. The function is then applied to slot"n" each time the button is pressed.

View 5 Replies







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