Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Multiple versions of Excel and GetObject/CreateObject
Message
From
16/11/2007 13:49:31
 
 
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
01269423
Message ID:
01269498
Views:
31
Fred--

>
>That's because GETOBJECT uses whatever is currently running. Version makes no difference. You could check the version via automation once you've gotten the object reference.
>
oX = GETOBJECT(,"Excel.Application")
>?oX.Version   && Excel2003 is 11.0
Thanks.

Is there some easy way for me to detect that the version of Excel that fired up is a Trial version. The trial version of Excel 2007 has Save As disabled. I can TRY/CATCH that to detect that I got the Trial by mistake. That is a little to indirect for my taste.

More importantly, if I print using Automation in Word, everything works the first time. The 2nd time my app is run my print image is garbage. My VFP app is called from a FPW 2.5 app. Every time my user prints, the VFP app EXE is started up. Regardless, my VFP app does

oDocument.Application.quit
RELEASE oDocument

after printing.

When I reboot Vista, the first print is good again. Somehow there is some Word stuff hanging out in memory. This is running on 15 XP systems without issue.

Tim
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform