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...

About Virtual functions and their use ?

Answer Posted / belson gnana pradeep

Virtual methods those can be overridden and replaced by sub classes.
When working with virtual methods keep in mind datatype of
an object is used to determine the implementation of
the method to call, rather than the type of the variable
that refers to an object.

In C#, a base class must provide the "virtual" modifier for
any virtual method, and derived classes must provide the
"override" modifier for any overriden method inherited from
a base class.

In VB.NET, a base class must provide the "Overridable"
modifier for any virtual method, and derived classes may
provide the optional "Overrides" modifier for any overriden
method inherited from a base class

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can an interface extend a class c#?

962


What is the use of command builder?

1046


What is the use of console readline () in c#?

873


If you want to write your own dot net language, what steps you will u take care?

986


Can we inherit abstract class in c#?

925


Enlist some of the properties of a thread class?

931


Why to use lock statement in c#?

937


Can we make a Static Constructor Parameterized? Give Reason with your answer

975


Is it possible to restrict the scope of a field/method of a class to the classes in the same namespace?

988


How many constructors can a class have in c#?

916


What are the advantages of clr procedure over t-sql procedure?

1002


List down the different ide’s provided by microsoft for c# development.

890


What is literal control

1020


Do extension methods have to be static?

1027


Can you create an instance of a static class?

999