Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to check that a OLE server was correctly instanciate
Message
 
To
28/02/2000 16:06:32
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00338617
Message ID:
00338690
Views:
19
>Thanks for your reply Éric, I've modified my code to use the method you've showed.
>
>Is there another way of verifying that the DLL instanciated correctly other than using On Error? In VFP, I would do the following:
>
>
loDLL = NewObject("DEXLink.DEXLink")
>
>IF VarType(loDLL) <> "O"
>   *-- Error message goes here
>ENDIF
No, because as soon as you check the object, it will create the instance.

>In VB, I get an error on the second line:
>
Dim loUtility As dexutility.dexutility   '<-- OK
>Set loUtility = New dexutility.dexutility   '<-- Error
Which error? Why does your component name and your class name the same? Did you create the component yourself? If so, what is the instancing property value?
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform