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

is it possible to inherit a class but methods declared in
the class should not be inheritable i possible how?

Answer Posted / aakanchha

Yes..!!
We can define a method as "private" ,so the method will not
be inherited.

and by 'sealed' we can prevent overriding but can not
prevent inheriting .

Is This Answer Correct ?    17 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain about Error handling and how this is done

952


How do you declare a variable in c#?

976


What's your approach to fetch static data in your windows form application?

1007


Name any three ways to pass parameters to a method in c#?

926


What is extension method in c sharp?

910


How can you sort strings in array that are passed to method as arguments?

1004


What is the difference between overriding and overloading in systemverilog?

998


What is difference between string and string builder?

980


Can properties be static in c#?

1008


Is string primitive?

877


What do you mean by abstract class in c#?

976


Why we need get set property in c#?

973


What is getenumerator?

859


Is a c# interface the same as a c++ abstract class?

976


What is eager and lazy loading in c#?

1015