Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Converting excel macro to VFP
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00261234
Message ID:
00261485
Views:
41
John,

My suggestion left something out. This should work.
oExcel.ActiveChart.SetSourceData(.Sheets("cheqsale").Range("AB4:AB8"),xlColumns)

You may need to add this line too.
oExcel.ActiveChart.Location(xlLocationAsObject,"cheqsale")

Using WITH/ENDWITH will be better.

WITH oExcel.ActiveChart
.SetSourceData(.Sheets("cheqsale").Range("AB4:AB8"),xlColumns)
.Location(xlLocationAsObject,"cheqsale")
ENDWITH

Sorry I did not notice the missing period.

Tom Molloy
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform