Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
FGETS
Message
De
31/05/2001 17:45:55
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Re: FGETS
Divers
Thread ID:
00513455
Message ID:
00513478
Vues:
17
>I forgot to change the title. Ignor that.
>sherry

Good because fgets has a bug with long lines (8192 as I remember).
Memo fields are ignored-skipped with 'appen from', 'copy to' commands.
alines comes to mind at first but would fail on long strings too.
You might choose one of multipl ways :
1) Create a cursor with n columns each c(250) -n could be calculated as :
ceiling(Fsize(YourTextFile)/Occurs(chr(13),FileToStr(YourTextFile)))
append from type sdf
scan..endscan to process
2) Directly process with lowlevel using fread() (my preference)
3) Create a cursor with one memo field
append memo from yourtxt
process memo
4)FileToStr() and process string
etc
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform