VB.NET equivalent of C# "As"
It is TryCast:
Dim x As String = TryCast(y, String)
If x Is Nothing Then ...
Trycast is what you're looking for.
Dim x = TryCast(y, String)
TryCast:
Dim x = TryCast(y, String)
if (x Is Nothing) ...
It is TryCast:
Dim x As String = TryCast(y, String)
If x Is Nothing Then ...
Trycast is what you're looking for.
Dim x = TryCast(y, String)
TryCast:
Dim x = TryCast(y, String)
if (x Is Nothing) ...