Can you allow class to be inherited, but prevent the method
from being over-ridden?

Answer Posted / sujai cn

By using NEW key word with implementation of method (which
is declared as virtual in base class) in the derived class

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between returning iqueryable vs ienumerable?

699


Is concurrent queue thread safe?

680


Is c# lazy thread safe?

681


What are escape sequences explain with example?

741


What are generations and how are they used by the garbage collector?

719


What is asp net in c#?

714


How do you declare an interface in c#?

657


Explain About delegates

802


What is fcl in c#?

671


What is reflection in c#?

670


In a site to turn off cookies for one page which method is followed?

726


Why ref is used in c#?

651


How are methods overloaded?

744


What is strong data type in c#?

674


How to prevent the error while updating ui control from another thread?

709