I have a function which has a selectedID parameter of type "object".
If my parameter is the default for the underlying type: i.e. Integer default is zero, I want some action to take place.
Without "Strict On", I can use:
If selectedID = Nothing Then
'Do Something
End If
Do I have to do something like:
If (TypeOf selectedID Is Integer AndAlso selectedID.Equals(0)) _
OrElse (TypeOf selectedID Is String AndAlso selectedID.Equals(Nothing)) _
OrElse .. other types go here .. Then
'Do something
End If
Or is there a simpler method that I'm missing?