Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
I Finally Got FoxPro and Excel to Work Together!
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
I Finally Got FoxPro and Excel to Work Together!
Miscellaneous
Thread ID:
00122058
Message ID:
00122058
Views:
58
Thanks to those who helped me load an Excel spreadsheet by calling Excel from FoxPro.

I wanted a straight-forward approach, without needing to utilize libraries or DDE. So, here's what I came up with:

-----

loTempSheet = GetObject('','excel.sheet')
oVar.ExcelApp = loTempSheet.Application
oVar.ExcelApp.Visible = .T.
oVar.ExcelApp.Workbooks.Open("c:\agetemp")

-----

"oVar" is a public variable I use for attaching variables as properties. This way, I can keep all public variables in one place, as an object.

The "agetemp" Excel file is created beforehand, after a selection is made on a grid.

Thanks a LOT!

Michael Reynolds
Reply
Map
View

Click here to load this message in the networking platform