when i m calling the CallMe method from derived class instace and object it calls only the Abstract method not the interface method why so can anyone spread some light on it??
it works fine if i create object of interface and abstract and allocate memory of derived class.
interface M1 { void CallMe();
}
public abstract class ME { public abstract void CallMe();
public class Derive:ME, M1 { void M1.CallMe() { Console.WriteLine("I am interface method"); }
public override void CallMe() { Console.WriteLine("I am abstract class method"); }
class Program {
static void Main(string[] args) { Derive obj = new Derive(); obj.CallMe();
Console.ReadLine();
} }
Output: I am abstract class method