If a base class has a bunch of overloaded constructors, and
an inherited class has another bunch of overloaded
constructors, can you enforce a call from an inherited
constructor to an arbitrary base constructor?

Answer Posted / js_m

yes, for example

class Root
{
public Root(int id) {...}
}

class Derived
{
public Derived (int id) : base(id)
{}
}

'public Derived (int id) : base(id)' does the need ful.

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to sign an assembly with strong name?

655


Is dll a library?

580


How many variables do you need?

584


What are async and await?

632


How do I do implement a trace?

653






What is data adapter in c#?

547


What are tuples c#?

567


What is a generic in c#?

579


What is jit (just in time)?

643


What does void mean in c#?

605


Do events have return type c#?

598


Explain what are the steps for creating clr trigger?

543


What are bitwise logical operators?

566


Define a jagged array in c#?

570


What is xor operator in c#?

601