Short and null
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
4 Answers
Know the answer? Post it. Somebody with the same question will find it here.

shimtannyRank #3,312 · 434 pointsPosted Mar 13, 2005, 11:41 AM EST
mibuytRank #3,026 · 476 pointsPosted Mar 13, 2005, 3:58 PM EST
sacrespRank #1,944 · 754 pointsPosted Mar 15, 2005, 4:36 AM EST
shimtannyRank #3,312 · 434 pointsPosted Mar 15, 2005, 6:26 AM EST