Solved

Loading variables from a text file

Posted on 2000-04-13
8
147 Views
Last Modified: 2010-04-03
I have done this many times over but this time I can't seem to get it to work.

Here's what I have...

I have a file called test.txt with the contents below:

?Name=Dan

In the first frame of the movie the actionscript reads

Load Variables ("test.txt", 1)

I would figure that the text field called Name I have in my movie would then be filled with the name "Dan".

Can anybody give me a clue here?

-D
0
Comment
Question by:SuperMario
8 Comments
 
LVL 4

Expert Comment

by:RoyKruyshaar
ID: 2718601
Hi SuperMario,

The 1 must be a 0, unless you work with several levels.
Good Luck

Roy
0
 
LVL 3

Author Comment

by:SuperMario
ID: 2719202
Oops...

My bad, Roy, I should have left out the question mark. It still works for me when I use a 1 because the variable itself is within a movie clip.

Sorry mon, fixed it myself.

-D
0
 
LVL 4

Accepted Solution

by:
RoyKruyshaar earned 50 total points
ID: 2719229
When you use more variables, you should use a '&' between them.
Do you have more questions about this, because your question is still standing in de question area?
0
 
LVL 3

Author Comment

by:SuperMario
ID: 2719238
Well, I've done this many times before and it's always been through a query string in a script which starts with ? but from a text file it shouldn't have a ? there.

Thanks anyway, Roy, I appreciate it!

-Dan
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 7

Expert Comment

by:ssdesign
ID: 2723585
Edit you movie in the following manner

Name the text field box ..... name

rename the text file as ...... name.txt

In the action to load variable write

LoadVariables("name.txt",0)

In the text file named name.txt begin the text you want to load with name=yourtext
0
 
LVL 3

Author Comment

by:SuperMario
ID: 2724541
Actually...
I already fixed it, see the above comment?

Sorry... this question should be closed.
0
 
LVL 3

Expert Comment

by:davlun20080
ID: 2758248
You will have to ask that this question be deleted from the folks in the customer service area of this site.
0
 
LVL 3

Author Comment

by:SuperMario
ID: 2802745
Thanks for the level tip, Roy. =)

-D
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I know the transition can be hard. We got used to the ease of use ActionScript 2 had, but honestly, it became problematic later on, especially if designers were involved in the project and found it easy to add code as they saw fit. So, this artic…
Here are some practices and techniques that can be adopted into your Flash/Flex application development process. Note: Not all "performance tips" provide an immediately-recognizable benefit.   This article does not include timing validation data,…
The goal of the tutorial is to teach the user how to set there setting in Adobe Flash Media Live Encoder and YouTube for optimal video and audio quality.
The goal of the tutorial is to teach the user how to select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now