HI
What is Base class In Vb.net With example?
HI
What is Base class In Vb.net With example?
Your questions is too vast to explain here. That is beyond the scope of this discussion . Kindly follow a good book or manual on the topic or you can find a lot of related topic by little web searching,
Courtesy : http://www.startvbdotnet.com/oop/inheritance.aspx
Once a class has been written and tested, it can be used by other programs to suit the program's requirement. This is done by creating a new class from an existing class. The process of deriving a new class from an existing class is called Inheritance. The old class is called the base class and the new class is called derived class. The derived class inherits some or everything of the base class. In Visual Basic we use the Inherits keyword to inherit one class from other.
hello mahesh,
you can see the following example:
class person
public name as string
public address as string
public city as string
public state as string
public zip as string
end classclass employee
public name as string
public address as string
public city as string
public state as string
public salary as integer
end classclass employee
inherits person
public salary as integer
end classIn the above example, employee is the derived class and person is the base class. Visual basic .net supports only single inheritance, which means that a class can derive from only one base type. However, you can use multiple inheritance if you use interfaces.
Last edited by gmeena1982; 10-15-2007 at 07:39 AM.