This exception occur when your are try to access a property,field of a object which
is not intialized to some valid value. Means it is null
or a dynamic object which does not exists
For example:
object a=null;
a.ToString();
This will throw exception "object reference not set to an instance of an object"
Regards
Raj
3 comments:
Thanx for you reply. I often find this error. Thanx Sir
is it C++ (thats all my knowledge permits me to comment)
No this is c#. Actually it's most of syntax is from c++. I thought that's why it seeeming u like C++.
Post a Comment