Can you declare the override method static while the
original method is non-static?

Answers were Sorted based on User's Feedback



Can you declare the override method static while the original method is non-static?..

Answer / guest

No, you can?t, the signature of the virtual method must
remain the same, only the keyword virtual is changed to
keyword override.

Is This Answer Correct ?    11 Yes 0 No

Can you declare the override method static while the original method is non-static?..

Answer / kishore.a

To override an method we need to explicitly mention
override keyword in the child class and virtual or abstract
keyword in base class.

Here in this case neither of the keywords are used.Hence it
is not possible..

Is This Answer Correct ?    6 Yes 0 No

Can you declare the override method static while the original method is non-static?..

Answer / ashish gupta

I don think so...
even static members can not be marked as a virtual,abstract
or override.

Is This Answer Correct ?    5 Yes 0 No

Can you declare the override method static while the original method is non-static?..

Answer / saubhagya

No

Is This Answer Correct ?    3 Yes 0 No

Can you declare the override method static while the original method is non-static?..

Answer / kishore

No we cannot declare ovverride method of static while the
first one is non static..

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More C Sharp Interview Questions

What is the difference between abstraction and encapsulation in c#?

0 Answers  


How to use reflection to call generic method?

0 Answers  


What are partial types in c#?

0 Answers  


Tell me the difference between value passing and address passing?

0 Answers   NIIT,


What is the extension of c# file?

0 Answers  






What are the new features in c# 2.0?

0 Answers  


Can we call server-side code (c# or vb.net code) from javascript?

0 Answers  


How does the lifecycle of Windows services differ from Standard EXE?

0 Answers   Siebel Systems,


Why can?t you specify the accessibility modifier for methods inside the interface?

3 Answers   Mind Tree, Siebel Systems,


Is string a class in c#?

0 Answers  


Is dictionary reference type c#?

0 Answers  


Explain the process of inheriting a class into another class?

0 Answers  


Categories