Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sending Variables

Status
Not open for further replies.
Dec 24, 2001
857
GB
I've got a collection of about 50 small movies which are all linked via the 'UnloadMovie' and 'LoadMovie' commands. I noticed the send variable choice, where you select either 'Send using GET' or 'Send using POST'.

Anyway, my idea is that after the whole lot of movies play through 4 times, it loads another movie (sort of like an advertisement but doesn't happen everytime). I was thinking of using something like 'set "test"=test+1' and when test=4 load this other movie and set test back as 1.

Does anyone have any ideas on how to do this because I can't seem to get it to send the variable.

This is going to be on a stand alone machine and all movies are stored in the same folder. If you need any more info, let me know and I'll post it.

Rgds
 
In your movie loaded first (level 0) add a var ie. variable = 1; // of course it will work only if the movie remains on level 0.(or any other level)

Then whenever you want to increment it use:
_level0/:variable = variable+1;

Then you can check if it reaches 4:

if (_level0/:variable == 4) {
"your action here";
}

Hope it'll help ;-) Have Fun...

Sharky99 >:):O>
 
The problem I'm having is how do I send variables between seperate movies? I can do the variable=variable+1 bit (I ran a seperate test for that which worked).

Imagine I have a stand alone computer where it'll be running these movies through Flash Player. I can't get movie 1 to send its variables to movie 2, then movie 2 to send to movie 3 etc.

An alternative method I've thought of is can Flash create files, delete files and check for files? All I would do here is get my very last movie to create a file. Once four are created, it deletes them, loads a new movie, then continues the cycle.

Thanks for the help.

Rgds
 
Is it actually possible to send variables between two movies which are just using Flash Player (through the exe file rather than through IE).

I'm having a few problems with this, so if someone knows, can you tell me what I need to do.

Rgds
 
AS Sharky99 said u can use level 0 movie this mean the first movie everything is in it.Every other movie.So u can put global variable that will increase or decrease depend.Or i suggest u to use it a Random functon that is lot better

Have fun
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top