Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to determine if var = nothing
Message
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00413401
Message ID:
00413477
Views:
14
>>"Is Nothing" in stead of "= nothing"
>
>So the opposite (which is what I need would be:
>
>
If Not oTest Is Nothing Then
>    MsgBox ("object")
>Else
>    MsgBox ("nothing")
>End If
>
>correct?

I prefer a lot this syntax:
If oTest Is Nothing Then
    MsgBox ("nothing")
Else
    MsgBox ("object")
End If
É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