NeuralJack
Centurion
- Joined
- Jul 28, 2005
- Messages
- 138
Sometimes when I define a variable holding a class I dont want to instantiate it until later.. possibly in another function even. This means for safety I'd like to be able to test that it's been instantiated before I acutally use it, to avoid errors. So how can I test for instantiation of a class I made?
'But i'm pretty sure that <> Nothing doesnt work on classes
Visual Basic:
Dim Bob as MyClass 'Not instantiated
'So i want something like ..
If Bob <> Nothing Then
'Continue..
End if