I am probably being incredibly thick and not understanding depth, i am new to this!!
I thought the higher the depth number the closer to the viewer it was?
I have created a movie which pulls back info from a database, on the original movie, once all the data was loaded, i created the required number of dynamic text boxes on the _root and everything worked perfectly.
I then decided that i would need to display other information on other movie clips. So i decided to turn the movie into a movie clip, so that i could create other movie clips and load these as needed.
I created a new blank movie, attached a blank movieclip(depth 0) as a container for the movie clips that will hold the different data, i then used attachMovie(depth 1) to attach the original movieclip, which holds the database info. I then changed the original movie, so that it would create the text boxes in this movie clip(depth 3), so that when i decided to load another movie, i don’t have to clear up text boxes on the root.
When i run the movie, i get the background image for the data movie clip, but i don’t see the text. I used trace to make sure that the text boxes were being created and the text values were assigned and they are. So why can’t i see the text???
Be as sarcastic as you like, if this is very easy, i just need the answer!!
I´m sure you´ll have this question (and all others you migh have in the future) fully answered, and I hope you stick around
about the question: I found it a bit confusing, but I can point you a problem, never load anything on level 0, this level is for the main movie, the one that all others will be loaded in to. Maybe this don´t fix all your problems, but it´s a good start.
This is the code that i have put in the nested_mc:
this.createTextField(“test3”,0,300,150,300,25);
test3.text =“this is the text from the nested_mc”;
start1 = new TextFormat();
start1.size = 20;
start1.color = (0xffffff);
start1.align=“center”;
test3.setTextFormat(start1);
It wasn’t working before, i thought that the depth mattered??
I thought when you created a new TextField through actionscript they all had to be at different depths?? Am i getting depths and things wrong??
Ok i thought i had this sorted but i don’t, so more help is required.
In the real movie i am trying to pull back some info from a database, in this test fla i have substituted a text file in its place.
In the text file i have rsCount=Hello World, i then created a dynamic text box in the nested MC, and use loadVariablesNum to pull back the value. I can get this to work when i create the text box on the root, please tell me what i am doing wrong…
Panic over i have fixed it again, after much messing about,
i was using loadVariablesNum(“blahblah”,2) but when i was referencing the rsCount variable i didn’t realise that i had to use “_level2.rsCount”. I had also forgot to put the code within onEnterFrame, so it was doing it once and so the variables were never being loaded.
Any info on whether there is a better way of doing this would still be appreciated.