Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Importing a worksheet form an Excel workbook
Message
De
09/09/1998 13:20:15
 
 
À
09/09/1998 11:54:25
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00134561
Message ID:
00134634
Vues:
15
John ---

Thanks! Just what I needed.
I guess it's time I shed my distaste for ms office apps and learn vb for apps.

>Tom ---
>
>Try the following (it may need some tweaking)
>
>oExcel=CREATEOBJECT("Excel.Application")
>oExcel.Workbooks.Open("XLSFileName.XLS")
>FOR nCounter = 1 TO oExcel.Worksheets.Count
>   DIME cWorkSheets(nCounter)  &&& Dynamic resizing of array is OK
>   cWorkSheets(nCounter) = oExcel.Worksheets(nCounter).Name
>ENDFOR
>
>
>
>
>>Does anyone know of a method that can determine from VFP the number and/or name of the wooksheets in an excel work book. I woluld like to allow the users to select the actual worksheet prior to import instead of requiring all data be contained on sheet1. Thanks!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform