Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Opening Excel from a Form
Message
From
27/01/2003 12:34:01
 
 
To
27/01/2003 11:59:33
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00745826
Message ID:
00745856
Views:
23
Dear Billy

Please try the following code in the click event of the commandbutton:

lcOldError=on("ERROR")
on Error oExcel=.NULL.
oExcel=GetObject(,"Excel.Application")
onError &lcOldError
IF isnull(oExcel)
oexcel=CreateObject("Excel.Application")
Endif
oEXCEL.workbooks.open('Excelfile.XLS')

&&Where excelfile is the file you want to open

Regards,

Steve.
Previous
Reply
Map
View

Click here to load this message in the networking platform