Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Copy to a textfile
Message
From
31/01/2003 13:23:04
 
 
To
31/01/2003 12:21:50
William Sherman
Allegheny County Bar Association
Elizabeth, Pennsylvania, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00747717
Message ID:
00747755
Views:
12
Bill,

You can put in a character that will never be a part of the table, then use strtran() to replace it with spaces...something like below. It does have to write the file two times, so if the table is large there is a performance hit:
set safety off
lcOutFile = "customers.txt"
lcScrap = chr(15)
copy to (lcOutFile) type delimited with &lcScrap with character tab
strtofile(strtran(filetostr(lcOutFile),lcScrap,""),lcOutFile)
>When I use the following command to copy a dbf to a tab delimited text file:
>COPY TO MaxA1 DELIMITED WITH " " WITH CHARACTER TAB I get an extra space
>in my character text file columns. The reason I did this with blank is I don't want the ' " ' characters around character data which I get when delimted with just 'TAB'. I also do not want the extra space. I need a tab delimited file with just tabs. Could someone please tell me what I am doing wrong. I had written a low level but am having a problem with the decimals...so i think COPY TO is my best bet for now..
>Thanks a lot..
>Bill
Steve Gibson
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform