Click here to Skip to main content
15,851,090 members
Home / Discussions / C#
   

C#

 
GeneralRe: project file associated with c# application on start Pin
Member 1104538815-Jan-17 2:01
Member 1104538815-Jan-17 2:01 
GeneralRe: project file associated with c# application on start Pin
Eddy Vluggen15-Jan-17 2:06
professionalEddy Vluggen15-Jan-17 2:06 
GeneralRe: project file associated with c# application on start Pin
Member 1104538815-Jan-17 2:10
Member 1104538815-Jan-17 2:10 
GeneralRe: project file associated with c# application on start Pin
Eddy Vluggen15-Jan-17 2:24
professionalEddy Vluggen15-Jan-17 2:24 
GeneralRe: project file associated with c# application on start Pin
Member 1104538815-Jan-17 2:48
Member 1104538815-Jan-17 2:48 
GeneralRe: project file associated with c# application on start Pin
OriginalGriff15-Jan-17 2:23
mveOriginalGriff15-Jan-17 2:23 
GeneralRe: project file associated with c# application on start Pin
Eddy Vluggen15-Jan-17 2:25
professionalEddy Vluggen15-Jan-17 2:25 
QuestionCan't understand implementation of interface Pin
Mc_Topaz14-Jan-17 4:07
Mc_Topaz14-Jan-17 4:07 
I have an interface I need to implement. But one of the interface's members I cannot understand why the refactor in VS implement in a certain way.

Here is the interface. (Never mind the names for variables etc, I have changed them).
C#
using System;

public interface IStuff
{
   void SPB(string a, DateTime d, string c);
   void P(decimal a, string r);
   void EPB();
}

I have a class Stuff which implement the interface. Here is how VS implemented the interface for me.
C#
using System;

namespace Namespace1
{
    public class Stuff : IStuff
    {
        public void SPB(string a, DateTime d, string c)
        {
        }

        public void IStuff.P(decimal a, string r)
        {
        }

        void EPB()
        {
        }
    }
}

What I don't understand is why the P() method in the interface is implemented in the class as:
C#
public void IStuff.P(decimal a, string r)
{
}

Why not like this?
C#
public void P(decimal a, string r)
{
}

Why is this so? How do I access the P() method in the class?
What is going on here?
AnswerRe: Can't understand implementation of interface Pin
OriginalGriff14-Jan-17 4:48
mveOriginalGriff14-Jan-17 4:48 
PraiseRe: Can't understand implementation of interface Pin
Mc_Topaz14-Jan-17 5:35
Mc_Topaz14-Jan-17 5:35 
GeneralRe: Can't understand implementation of interface Pin
OriginalGriff14-Jan-17 5:46
mveOriginalGriff14-Jan-17 5:46 
SuggestionRe: Can't understand implementation of interface Pin
Richard Deeming16-Jan-17 3:18
mveRichard Deeming16-Jan-17 3:18 
AnswerRe: Can't understand implementation of interface Pin
BillWoodruff17-Jan-17 17:49
professionalBillWoodruff17-Jan-17 17:49 
QuestionDatatable to Excel Pin
Member 1294766512-Jan-17 12:41
Member 1294766512-Jan-17 12:41 
AnswerRe: Datatable to Excel Pin
Dave Kreskowiak12-Jan-17 12:50
mveDave Kreskowiak12-Jan-17 12:50 
GeneralRe: Datatable to Excel Pin
Chris Quinn13-Jan-17 4:53
Chris Quinn13-Jan-17 4:53 
GeneralRe: Datatable to Excel Pin
Dave Kreskowiak13-Jan-17 6:05
mveDave Kreskowiak13-Jan-17 6:05 
GeneralRe: Datatable to Excel Pin
Chris Quinn13-Jan-17 6:07
Chris Quinn13-Jan-17 6:07 
GeneralRe: Datatable to Excel Pin
theoldfool14-Jan-17 17:16
professionaltheoldfool14-Jan-17 17:16 
GeneralRe: Datatable to Excel Pin
Dave Kreskowiak14-Jan-17 17:45
mveDave Kreskowiak14-Jan-17 17:45 
GeneralRe: Datatable to Excel Pin
theoldfool15-Jan-17 3:21
professionaltheoldfool15-Jan-17 3:21 
AnswerRe: Datatable to Excel Pin
Brisingr Aerowing12-Jan-17 13:26
professionalBrisingr Aerowing12-Jan-17 13:26 
QuestionHow to Use Telerik Split button Pin
Member 1293879712-Jan-17 7:38
Member 1293879712-Jan-17 7:38 
AnswerRe: How to Use Telerik Split button Pin
NotPolitcallyCorrect12-Jan-17 9:03
NotPolitcallyCorrect12-Jan-17 9:03 
GeneralRe: How to Use Telerik Split button Pin
Member 1293879713-Jan-17 8:50
Member 1293879713-Jan-17 8:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.