Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Deleting top line in ASCII file.
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00490839
Message ID:
00490992
Vues:
11
>How would I delete the top line in an ASCII file with low level commands, such as: fopen() ,fputs(), fclose?
>
>TIA
>
>Jim

From the top of my head:
lcStr=filetostr("myfile.txt")
#define CRLF chr(13)+chr(10)
lnPos=at(CRLF,lcStr)
strtofile(substr(lcStr,lnPos+1),"myNewFile.txt")
Something like this.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform