If u declare two interfaces withsame methodnmae .prototype
how can u call the particular method from class?
Answer Posted / n.v.s prasad
By using explicit interface declaration which is nothing
but (Interfacename.Methodname) but the problem is method
available to interface not for class(if you careate
instance of your class we are not able to access method
which we implemented above in our class, so method is
availble to interface only)
Note:If you want to acess method by instance of your class
we need to cast our instance to 'interface'
((instance)interfacename).methodname--->Possible
instance.methodname ---->Not possible
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What's the c# syntax to catch any possible exception?
Explain code compilation in c#.
Is c# different than c++?
Is is possible to force garbage collector to run?
Can you have parameters for static constructors?
How do you serialize in c#?
What is the difference between final finally and finalize in c#?
What is difference between variable and property in c#?
Why do we override in c#?
What is master page in asp net c#?
Is vs as c#?
What is a clr (common language runtime)?
What is difference between il and dll ?
What is the use of getcommandlineargs() method in c#.net?
What does == mean in c sharp?