Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Delimited Text File with fields greater than 254 chars.
Message
De
25/04/2008 07:38:32
Emerson Reed
Folhamatic Tecnologia Em Sistemas
Americana - São Paulo, Brésil
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Divers
Thread ID:
01312930
Message ID:
01313093
Vues:
15
Hi Jim!
Try this:
Local lcLine
Create Cursor curTemp (Field1 C(254), Field2 C(254), ....)
Append From YourTextFile SDF
Go Top
Scan
   lcLine = curTemp.Field1 + curTemp.Field2 + ...
   * Now you can handle your text line with GetWordNum(), for example
EndScan
Use
You can also try using FOpen() and FGets().
Something like this:
Local lcTextFile, lnHandle, lcLine
lcTextFile = "C:\temp\test.txt"
lnHandle = FOpen(lcTextFile)
If lnHandle==-1
   * Error
Else
   FSeek(lnHandle,0,0)
   Do While Not FEof(lnHandle)
      lcLine = FGets(lnHandle,8192)
      * Now you can handle your line using lcLine variable
   EndDo
Endif
FClose(lnHandle)
Emerson Santon Reed
"One Developer CAN Make a Difference. A community CAN make a future." - Craig Boyd
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform