Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to import data into Excel using OLE object
Message
De
11/12/2003 03:02:35
 
 
À
10/12/2003 02:51:36
Agnes Cheng
DynamicTech Consultants Ltd.
Hong Kong, Hong Kong
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00857533
Message ID:
00857992
Vues:
23
>Hi,
>
> I would like to import data to Excel using OLE object. However, I don't
>know much about the structure of the Excel in terms of object. I only know
>how to create an excel and add a cell value in it using OLE object.
> So I would like to know is there any help file for describing how to
>import data into Excel using OLE object.
>
>Thanks,
>Agnes

Hi Agnes,

While ago I developed & posted here in download section file named REP2EXCEL.
It is set of wrapper classes for common OLE automation calls + reporting class. They can do this kind of stuff.
Exporting/reporting/writing to excel from VFP.

It might be little bit slow for exporting huge tables, but is extremely powerfull for complex Exports/Imports to/from excel.

Eg.
oXL.make_cell(3,20,5, 'Hello' )

will write word 'Hello' into 3rd sheet, 20th row and 5th column
of a desired excel file

or

oXL.table_in_section(3,21,5, 'MyTable',cDelimitedFieldsList)

will write specified fields of your cursor/table into section specified by given coordinates.

Full source is included so - suit yourself.

Rgds++


*****************
Srdjan Djordjevic
Limassol, Cyprus

Free Reporting Framework for VFP9 ;
www.Report-Sculptor.Com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform