I posted this on the Com and ActiveX forum with no luck. Would appreciate any help.
http://www.vbforums.com/showthread.php?threadid=85877
Printable View
I posted this on the Com and ActiveX forum with no luck. Would appreciate any help.
http://www.vbforums.com/showthread.php?threadid=85877
I posted to your original thread, but I'll post here as well. Try using the IsEmpty Command.
Example:
VB Code:
Private Sub Command1_Click() Dim ie As Object If IsEmpty(ie) = True Then ie.Visible = True Else MsgBox "called" Set ie = CreateObject("InternetExplorer.Application") ie.Visible = True End If End Sub
Hope this helps.
Alternative option, again, posted in the original thread:
I've always used Is Nothing:
- gaffaCode:If lobjObject Is Nothing then
Set lobjObject = new DummyObject
End iF