Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
EOF marker in csv, text files
Message
 
 
À
13/08/2001 08:44:51
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
Information générale
Forum:
Visual FoxPro
Catégorie:
FoxPro 2.x
Divers
Thread ID:
00542920
Message ID:
00542950
Vues:
21
Hilmar,
I'm sorry that my post was against your rules but it's actual working code that person can use right away. Yes, I've 2.6 version of Filetostr and Strtofile but I don't see a reason to rewrite working code.

>>In VFP 6 it can be done in a few lines of code
lcData = Filetostr("Myfile.csv")
>>IF ASC(RIGHT(lcData,1)) = 26    && make sure that its CTRL+Z
>>  = Strtofile(LEFT(lcData, LEN(lcData)-1), "Myfile.csv")
>>ENDIF
>
>Sergey,
>
>Instead of posting or using two different versions of a program, one with, one without, FileToStr() or StrToFile(), I suggest to always use FileToStr() and StrToFile(), even in older versions of VFP. These functions are so extremely handy that it is worthwhile to define them as UDFs in older versions - in fact, I wonder why I didn't create something similar before the advent of VFP6!
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform