File handling
- From: "Loonie" <no@xxxxxx>
- Date: Fri, 22 Jul 2005 07:10:38 GMT
I am trying to learn Delphi7,and have come to my next hurdle. I am trying
to read a text file of G codes, that i want to draw onto a canvas. The
trouble is i'm not sure of the best approach. The file is in the format
Gstart
G0X0Y0
G1X100Y100
G0X300Y500
G1X300Y800
etc etc
GEnd *End of G codes*
The G0 instruction is move to position, the G1 is a cut to some position.
Now i have in place a way of reading the file line by line and adding it to
a memo,with a button click. What i would like to do is draw the line as it
is added, and eventually automate the process. I know i have to read
through the line and find the Integers for X and Y, But how? And would it
be better to read the whole file first or take the line by line approach.
Thanks in advance
Dave
.
- Follow-Ups:
- Re: File handling
- From: J French
- Re: File handling
- Prev by Date: Re: Threads
- Next by Date: Re: File handling
- Previous by thread: Is anyone listening?
- Next by thread: Re: File handling
- Index(es):