Chintan Dave
Can we inherit Static Class in C# ?
By Chintan Dave in C# on Aug 22 2018
  • Ina Gupta
    Oct, 2018 3

    static classes are sealed classes , they can not be inherit

    • 4
  • Hitanshi Mehta
    Sep, 2018 28

    NO, we can not inherit static class in c# because they are sealed and abstract. There seems to be no good reason to inherit a static class. It has public static members that you can always access via the class name itself.

    • 4
  • Bhavesh Ghul
    Oct, 2018 19

    The compiler will guarantee that instances of this class cannot be created. Static classes are sealed and therefore cannot be inherited. They cannot inherit from any class except Object. ... For more information, see Static Constructors (C# Programming Guide)https://stackoverflow.com/questions/774181/why-cant-i-inherit-static-classes

    • 3
  • Sanjay Kumar
    Apr, 2022 23

    We can’t Inherit

    • 0
  • Sonil  Kumar
    Jul, 2021 27

    Any class which does not contain instance contructor, cannot be inherited. Static class by default do not have non-static contructor (instance contructor) and that is why you cannot inherit it.

    • 0
  • Saurabh Vasani
    Jul, 2019 26

    Not possible to inherit static class in c#. Basic usage of the static class is to make method and member static and can invoke by using name of the class without creating the object of the static class. The main purpose of the static class is to create only one istance of the member in the memory.

    • 0
  • Radhesham Khatri
    Jul, 2019 15

    No, When working with static class oop says static class is sealed and can not be inherited by another class.

    • 0
  • siva b
    Mar, 2019 13

    No, compilation error occurs .

    • 0
  • Amit Prakash
    Jan, 2019 2

    No

    • 0
  • Bhanuprasad Mitturi
    Nov, 2018 20

    static classes can't be inherited. we can not define static class as derived class from any class except Object class.

    • 0
  • Sreekanth Reddy
    Oct, 2018 23

    No, we can't.

    • 0
  • Madan Shekar
    Oct, 2018 18

    No you cannot inherit

    • 0
  • Vikas Agarwal
    Oct, 2018 5

    No, It's not possible to inherit Static class.

    • 0
  • Chandan Prasad
    Oct, 2018 4

    Static classes are sealed classes so we can't inherit that.

    • 0
  • Rasool baltee
    Oct, 2018 3

    yes

    • 0


Most Popular Job Functions


MOST LIKED QUESTIONS