Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

can it possible to acees the virthual method using the
override method object?
plz give me the example

Answer Posted / javed khan

public class zzz
{
public static void Main()
{
yyy x = new xxx();
x.test();

}
}
class yyy
{
public virtual void test()
{
System.Console.WriteLine("base calss.");
}
}
class xxx : yyy
{
public override void test()
{

System.Console.WriteLine("derived calss.");
base.test();
}
}

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why we use get set in c#?

942


Explain the difference between a struct and a class?

960


Explain namespaces in c#.

1009


Why is it called c sharp?

941


What is an object pool in .net?

1054


What does dbml mean in texting?

929


What are the 2 kinds of data type conversions in c#?

894


What is the lock statement in c#?

1001


Why do we use static methods in c#?

1013


What is dao in c#?

877


Define satellite Assembly in .NET?

994


What is the difference between Decorator and Adapter pattern?

977


What are actions in c#?

883


What is c# in asp net?

931


What is an enumerator c#?

921