Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Export a database into a Fixed Width Text Quesiton?

Status
Not open for further replies.
May 11, 2005
6
I have a database called mail.dbf.

I exported it into an ASCII Fixed Width Text using this command:

copy to mail.txt type sdf

I need to export it into an ASCII Fixed Width Text file but I need to take off the end of file marker. Thanks for the help.

Jarrett
 
f1 = fopen("mail.txt")
f2 = fcreate("newmail.txt")

do while not feof(f1)
b = fread(f1, 1)
if not inlist(b, chr(13), chr(10), <added as needed>)
= fwrite(f2, b)
endif
enddo

=fclose(f1)
=fclose(f2)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top