Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Launching Excel from within FoxPro
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00120781
Message ID:
00120808
Views:
22
Hey Crooner,

>? type('oxcel.application')='O'

This code is not foolproof. Consider this:

o = createobject("excel.application")
?type("o.application.name") && "C"
o = null
?type("o") && still evaluates to "O"
?type("o.application.name") && "U"

Best to check for data type of the Name Property. Or combine things like this:

!isnull(o) and type("o") = "O"
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform