4
Answers

Short and null

Ask a question
gicio

gicio

19y
3.9k
1
HI!! Let say I have an object and this object has a property of the type short. How I can check if someone set this property? When i try to check this like that: if( myObject.MyShortProperty != null ) { } I get an null reference exception. How I can check this without a null references exception? regards, gicio

Answers (4)