Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Cant seem to import xls file
Message
De
15/02/2017 07:35:51
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
01647967
Message ID:
01647977
Vues:
37
>My code is
>
>CLEAR
>CLEAR ALL
>USE c:\global\globalin IN 0 EXCLUSIVE
>SELECT globalin
>ZAP
>append FROM j:\global\ss\aaa.xls TYPE xls
>
>Microsoft Excel file format is invalid
>
>
>
>What am I doing wrong?

Hi Colin,
VFP is only capable of appending/importing rather old formats (xl5 and earlier). That practically means you cannot use append from or import with Excel files. Instead you can directly connect to excel via OLEDB or ODBC and get your data. Check this for detailed explanations and code(s) to do that:

https://www.foxite.com/archives/0000153776.htm

Also a note: Do NOT rename an XLSX with an XLS extension. If you do that even Excel itself is confused about the format of file (XLSX is a compressed XML format while XLS was binary).
Ç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