Reading in Data from Text Files

Hi, ok I admittedly haven’t spent enough time thinking of this (I’m going to do this now) but figured I’d toss it out there while I put in some time.

I have a daily schedule which is different every day. The schedule is known about 2 weeks in advance. Therefore every week or so I have to go in & change the file so I’m always about 1 week ahead.

ok, i’d like to simply edit a text file & upload it to the server.
The problems are I’d like to make this schedule much like the draggle menu tutorial.

I’m going to make the daily schedule 1 big movie clip & mask it so when it loads you’re looking @ today schedule & you can dragger a dragger to the right to see the schedule for future days.

Once I convert these to symbols my ability to read in variables will be lost (or @ least I think)

Can anyone give me some pointers to make this a little earier.
Also, is it possible w/ flash alone (no php) to have the movie clip dynamically change its position to the area holding todays date on load.

Thanks in advance.


so you want to make it like the dragger tutorial but each block would be a different day? Well, just make the blocks into different Text boxes and give them different names and give the variables in the TEXT file different names. Do you know how to do that? the text file would be something like this

monday=Milk the cow&tuesday=Churn the butter&wednesday=Give Ma some lovin’ etc…no space between the next variable and the “&”

then on the movie you would have in the first frame

loadvariables (exact URL)

and then just name the text boxes monday tuesday wednesday etc… and have them inside the main MOVIE clip that you will be dragging…

do you understnad? i didn’t test it but it should work…

Makes perfect sense Jubba. Jubba to the rescue again.
Thank you. Only other issue is let say my text file has = Monday, Tuesday, Wednesday, Thursday & so on.

Today is tuesday, so when the vistor comes to the page I’d like them to see tuesday displayed in the mask so basically the _x position of tuesday would have to change based on the date. How in the hell do I do that?
Thanks again. Your input is hugely appreciated.

& actually getDate returns the systems date stored on the visitors PC. I guess I’d be @ their mercy to have a correct sys date of my menu would not work correctly. I guess PHP would be the only way?

no it could be done with if statements. Check out my digital clock tutorial to figure out how to get the day and then do this

put everything in the timeline…

if (day == 0){
_root.general._x = whatever
}else if (day == 1){
_root.general._x = whatever

etc etc

the getDay function is 0 based I’m pretty sure so its 0-6 instead of 1-7

@ the moment this page isn’t loading:…cripts.asp
is this where your D Click Tut is?

Thanks Jubba, You’re the man…_clock.asp

there you go. Sorry about that, i was too lazy to look for it earlier. I have that 10 page paper due tomorrow and I only have a page done!! if you need anything else you can always IM me. JubbaORF

I’m reading in data from some text files. I’ve included (for example) very simple html tag in the text files & I’m see the tags when the file reads in. What am I doing wrong?

Sorry, had a case of idiot attack.
I forgot to check “html” in the dynamic text box properties field. Problem solved. Sorry for asking.

ok, I see the **[u] & so on work fine.
What about <table><tr><td>
How can I organize my text file data into a table?
Thanks a lot,

tables are tough… Flash is taking advantage of XML based data structures though. If you’ve not at least looked into these, I suggest taking a gander.

I’m still working through these problems myself.:slight_smile:

I guess this answers some questions for those having the same trouble:…mltext.htm

If you happen to find out any info on tables please pass it along. It would be a great thing to be able to do. It one thing I really miss when using flash instead of good old HTML.

Thank you

When I’ve done tables, I’ve imported the data, then in flash processed it into an array, then used that array data to fill in multiple dynamic text fields. I haven’t found another way of doing it as this seems to be simple enough for me to accomplish.

basicaly I’m just buildng the tables myself in a flash way.

I have a text file I want to read into a dynamic text box.
Anyway, this file is a schedule I must updated on a weekly
basis. Having it in text file format would make life easier as far
as updating. However, flash is weak when it comes to html. Basically I have a list of events & the time each event will occur. for example i’d like to have it like this:
Race 1 2:00
Race 2 2:15

& so on.
I’d like to keep these in neat columnar style. Basically,
I just want things to line up nicely.
How can I do this without having a text box to
the the race # & a seperate text box to hold the time???

Basically, I want to know how to format better using html inside the flash environment?

Thanks alot,


Just another question. ok, I have a dynamic text box receiving it’s data from an external .txt file. Some lines of text being read in may be say just 10 characters in length, some may be 100 characters in length. How do I make the size of the dynamic text box dynamic. @ the moment I have the data coming in & the right side is being cut-off as it travels outside the boundaries of the dynamic text box. Bear in mind I do not want the text here to wrap. Thanks again, much appreciated,