Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Excel Worksheet SaveAs Problem
Message
From
22/12/2011 22:12:36
Yim Ming Sun Derek
Spacious Design Consultant
Hong Kong, Hong Kong
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Excel Worksheet SaveAs Problem
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01531599
Message ID:
01531599
Views:
95
Hi,
I want to create a worksheet with a filename assigned before open it, I use following code,
but not success to SaveAs the file and open it.
cxlsfile="ABC.xls"
oExcel = CREATEOBJECT([Excel.Application])
oWorkbook = oExcel.Workbooks.Add()	
oWorkbook = oExcel.Workbooks.SaveAs(cxlsfile, xlNormal) 
oWorkbook = oExcel.Workbooks.open(cxlsfile) 
Please advise what is wrong.

Thanks.

Derek
Next
Reply
Map
View

Click here to load this message in the networking platform