Groups | Blog | Home
all groups > flash actionscript > december 2005 >

flash actionscript : actionscript and text's lines..


nightmare3d
12/24/2005 2:00:24 PM
i want to get data from text file (txt) but, i want for ex: in get line 4 in
text file....

sample:

i have this txt file:



Mehmet Mustafa
Huseyin Halil
Recep Advar


and i want to get data from line 2 and write a dynamic text box in flash.

what can i do?
kglad
12/24/2005 3:53:41 PM
you have to change your text file. it must be in the form of:

someVar=Mehmet Mustafa
Huseyin Halil
Recep Advar

or

someVar=
Mehmet Mustafa
Huseyin Halil
Recep Advar

nightmare3d
12/25/2005 8:44:32 AM
thans friend,

but;

kglad
12/25/2005 4:04:55 PM
lv=new LoadVars();
lv.load("yourTextFile.txt");
lv.onLoad=function(){
textA=this.someVar.split("\r").join(",,").split("\n").join(",,").split(",,");
yourTF.text=textA[1];
nightmare3d
12/25/2005 7:01:02 PM
thanks kglad,

i try it but do not.

kglad
12/25/2005 8:31:24 PM
nightmare3d
12/26/2005 7:39:42 AM
sorry for the duplicated messages , but not interesting me.

@kglad

kglad
12/26/2005 5:03:30 PM
nightmare3d
12/26/2005 5:59:00 PM
do not it...

files are in
http://www.nightmare3d.com/test.rar

kglad
12/26/2005 7:50:18 PM
your corrected file:

nightmare3d
12/26/2005 8:27:07 PM
kglad
12/26/2005 11:56:48 PM
AddThis Social Bookmark Button