posted 8 years ago
Hi Rajiv,
In inheritance and parameterized contructor, there are few rules.
Rule 1 : If Derived class contructor is parameterless, there has to be 1 parameterless constructor in Base class
If you dont want to add a parameterless constructor in Base class, then
Rule 2 : Call the contructor of Base class in the Derived class contructor explicitly.
NOTE : The call must be the first statement in the Derived class constructor.