Sub-classing
C#
2
Posts
2
Posters
0
Views
1
Watching
-
what is sub-classing in C#, and hw to achive that.
-
what is sub-classing in C#, and hw to achive that.
//a.k.a inheritance. //so for example... public class ClassOne : ClassBase { //this class is a subclass of ClassBase } public class ClassTwo : ClassBase { //this class is a subclass of ClassBase } public class ClassBase { protected int X = 5; // The two subclasses can access this variable as its been "inherited" }