Posts

Showing posts from March, 2014

Can we implement interface with same method name?

Interface is similar to a class, and we implement interface by defining their method in class. Suppose we have same method in more than one interface. In this case there will be a question for interview. Q.    Can we implement interface with same method name? Ans. Yes by using explicit interface implementation. Lets see below example:   class Program     {         static void Main(string[] args)         {             MyInterface1 obj1 = new MyClass();             MyInterface2 obj2 = new MyClass();             obj1.func1();             obj2.func1();         }         interface MyInterface1         {             void func1();         }         interface MyInterface2         {             void func1();         }         class MyClass : MyInterface1, MyInterface2         {             void  MyInterface1.func1()             {                 Console.WriteLine("Hello1");             }             void MyInterface2.func1()             {    

What is safe control in SharePoint 2010?

In SharePoint Environment a developer can add ASPX file very easily. An ASPX file contains code which may affect the SharePoint environment. In simple words, there might be a security risk of security injection.