Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VBA for Excel 2000 SaveAs
Message
 
To
All
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
VBA for Excel 2000 SaveAs
Miscellaneous
Thread ID:
00331789
Message ID:
00331789
Views:
60
I am trying to SaveAs an Excel document to type .htm from Visual Foxpro. I thought that I had the correct syntax, but I keep getting an error that "Member SaveAs does not evaluate to an object.

Here is the code:

oExcel = CreateObject( "Excel.Application" )
oExcel.WorkBooks.Add
oExcel.Sheets(1).Select
oExcel.Range("A4").Select
oExcel.ActiveCell.FormulaR1C1 = "Account Number"

oExcel.Activeworkbook.SaveAs.Filename ="excel.htm"

TIA,
Steve McMahon
ZDI
San Diego
Steve McMahon
ZDI
San Diego
Next
Reply
Map
View

Click here to load this message in the networking platform