why all the types derived from object

Posted by Jameschowdare under Regular Expressions on 1/30/2010 | Views : 1009 | Status : [Member] | Replies : 1
class a
now above class a has inherited from default from object.

now class b inherits class a now (class b has which type it has(multiple)or(multi level)


Posted by: RtpHarry on: 1/31/2010 [Member] [MVP] Bronze

I am not sure what your exact question is but all of the classes in .net are inherited from a common Object data type to make it easy for you to convert data between each others types. The .ToString() method comes from the Object data type and all classes in the .net library must implement a ToString() which makes it easy to represent it and allows for possibilities such as serialization.

More details are in this article:

What did you mean by the class a / class b stuff you said?

Jameschowdare, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response