Dynamic text driving me nuts!

I’ve been trying to sort this for ages now and can’t get anywhere with it. Problem is dynamic text not loading - scenario is I have movie b loading onto a stage area in movie a.

Movie b has a dynamic text field instance name updatesField and var: textField. The external text file I am trying to load within this field as movie b loads is called updates.txt and I have added the following actionscript to an actions layer within movie b:

loadVariablesNum(“dynamictext/updates.txt”, 0);

the text loads fine when i test movie b but as soon as i try to view it when movie b is loaded within movie a no text loads. i thought that this was maybe something to do with targets so changed the actionscript to:

loadVariables(“dynamictext/updates.txt”, “this”);

my text file starts textfield=

hope this makes sense n hope someone has a clue what i’m doing wrong lol

On your movie b, place the following actions:[AS]var loadText = new LoadVars();
loadText.load(“updates.txt”);
//your txt file
loadText.onLoad = function(success) {
if (success) {
varTextField = this.textfield;
//varTextField is the name of the variable that the text field is associated with.
//textfield is the variable inside the txt file.
} else {
varTextField = “Error loading data”;
}
};[/AS]
Now create a TextField and on the Var field, use this:[AS]_root.varTextField[/AS]

Tried this - still getting the same problem. Text loads when I test movie B on it’s own but as soon as movie B is loaded within movie A nothing loads in the text field.

makes me think i’m going wrong somewhere with targets but can’t figure out where :*(

Possible to post a sample of your fla that invovles yoru scenario?

Regards,
Viru.

tried to post it but it telling me file is too big

posted it to my server - should’ve thought of this before:

zipfile

In you home.swf the variable name for you dynamic textfield is ‘_root.varTextField’ change it to varTextField.

That worked.

Prehaps you got confused with claudio’s instructions.

Regards,
Viru.

yayyyyyy thanks u 2!!

working perfectly now - just gotta put scrollers back on n i be sorted :thumb:
once again thanks - i really appreciate the help :slight_smile:

Im sure my instructions do work.
:-\

Your welcome.

V.

they do Claudio - i had included ‘_root.’ in front of ‘varTextField’ in the var field for the text field

just removed _root. like kO2n advised and it works gr8 :slight_smile:

Problem was when movie B was loaded into movie A the _root.varTextField didnt apply to the varTextField variable in movie B.

What i think anyway.

Regs,
V.

sounds like it to me - this is my first flash site so i no expert but i think when movie b is loaded within movie a the _root becomes the root of movie a. if that makes sense

Perfect.

i think finally some of this stuff is making sense to me lol

whello peepz

i have the same question to ask, dynamic text doesnt load anymore in the main movie, it does work on the other MC’s, but when i load it into the main movie the text just disapeared, only static text work, here an example:

http://members.lycos.nl/vietguy/test_site

oh and i’ve used some actions from the
http://www.kirupa.com/developer/mx/preloader_transition.htm
tutorial (thnx claudio)

so the extern text doesnt load
i can only see them when i change the text field into statictext and already put text in it, see the about section of
http://members.lycos.nl/vietguy/test_site

all the text and mc’s are extern files, exept the about section
can anybody help me?