Read file line per line 
Author Message
 Read file line per line

Hello,
how can I read one line each of a file? (Borland Turbo Pascal 6)
Thx,
Florian


Mon, 09 May 2005 01:39:59 GMT  
 Read file line per line

Quote:

> Hello,
> how can I read one line each of a file? (Borland Turbo Pascal 6)

Look up
-Assign
-Text
-ReadLn
-Reset

in your online help!

Wolf



Mon, 09 May 2005 00:50:25 GMT  
 Read file line per line

Quote:


>> Hello,
>> how can I read one line each of a file? (Borland Turbo Pascal 6)

> Look up
> -Assign
> -Text
> -ReadLn
> -Reset

My problem:
AFAIK I need a
Var F : File Of Dataset
What is my Dataset in this case?
Thx,
Florian


Mon, 09 May 2005 02:43:20 GMT  
 Read file line per line

Quote:



> >> Hello,
> >> how can I read one line each of a file? (Borland Turbo Pascal 6)

> > Look up
> > -Assign
> > -Text
> > -ReadLn
> > -Reset

> My problem:
> AFAIK I need a
> Var F : File Of Dataset
> What is my Dataset in this case?

Text!

var f: text; s:string;
begin
  assign(f,'datei');
  reset(f);
  ReadLn(f,s);
  WriteLn('Erste Zeile: ',s);
  close(f);
end.

hm, mir f?llt da gerade ein, dass ich ja mal was dazu geschrieben habe:
http://www.behrenhoff.de/pascal/dateien.html

Wolf



Mon, 09 May 2005 02:39:14 GMT  
 Read file line per line

Quote:



> >> Hello,
> >> how can I read one line each of a file? (Borland Turbo Pascal 6)

> > Look up
> > -Assign
> > -Text
> > -ReadLn
> > -Reset

> My problem:
> AFAIK I need a
> Var F : File Of Dataset
> What is my Dataset in this case?
> Thx,
> Florian

var F: text;

cheers hanford



Mon, 09 May 2005 02:50:55 GMT  
 Read file line per line

Quote:

>Var F : File Of Dataset

var f : text;

Quote:
>What is my Dataset in this case?

You don't have one. "file of type" are not supported by ReadLn & Co.

Vinzent.



Mon, 09 May 2005 04:03:36 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. DOS/VGA - Mouse with 90 characters per line

2. DOS/VGA - Mouse with 90 characters per line

3. Program that counts lines per second

4. Listbox with more than one line per entry

5. Reading complete line from file

6. Newbie question about moving thru table line by line

7. Can I turn 26 line mode to 50 line mode

8. Blank line between lines: HELP!

9. Trouble printing a BST line by line

10. Q: Reading > 255 chars per line out of a file

11. reading multiple numbers on one line.

12. Read Unix Lines

 

 
Powered by phpBB® Forum Software