Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Opening text file in Excel, fixed width, columns
Message
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Opening text file in Excel, fixed width, columns
Divers
Thread ID:
00743166
Message ID:
00743166
Vues:
74
Hi, I have just realized that Excel can open a text file, containing columns. And that it can place the columns ion the text file into Excel columns --- by using the fixed width options from File -- Open -- text file -- fixed widths.
How would I then convert the following, taken from a recording the keystrokes in Excel -- into vfp excel automation ccode.


Workbooks.OpenText Filename:="C:\d\tax\200210.txt", Origin:=xlWindows, _
StartRow:=1, DataType:=xlFixedWidth, FieldInfo:=Array(Array(0, 1), Array(14 _
, 1), Array(42, 1), Array(67, 1), Array(70, 1), Array(83, 1))

My guess that it would be something remotely like this but I can't figure out to get the Array stuff in there?

o = CREATEOBJECT('excel.application')
o.Application.Workbooks.Open(The_File, extra parameters, extra ?, extra? , ....... )


any help would be greaqtly appreciated.
Thanks
Steve
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform