Click here to Skip to main content
15,886,362 members
Home / Discussions / C#
   

C#

 
GeneralRe: Registerhotkey API example in C# Pin
crash8935-Jun-07 21:33
crash8935-Jun-07 21:33 
GeneralRe: Registerhotkey API example in C# Pin
Giorgi Dalakishvili5-Jun-07 21:36
mentorGiorgi Dalakishvili5-Jun-07 21:36 
QuestionCopying picture box Pin
Muammar©5-Jun-07 21:13
Muammar©5-Jun-07 21:13 
AnswerRe: Copying picture box Pin
Martin#5-Jun-07 21:34
Martin#5-Jun-07 21:34 
GeneralRe: Copying picture box Pin
Muammar©5-Jun-07 22:19
Muammar©5-Jun-07 22:19 
AnswerRe: Copying picture box Pin
Seishin#5-Jun-07 21:58
Seishin#5-Jun-07 21:58 
GeneralRe: Copying picture box Pin
Muammar©5-Jun-07 22:19
Muammar©5-Jun-07 22:19 
QuestionA typical case about interfaces [modified] Pin
amitcoder835-Jun-07 20:35
amitcoder835-Jun-07 20:35 
the following code is in C#

I have 2 interfaces

public interface Interface1
{
string ReturnString1();
}
public interface Interface2
{
string ReturnString1();
}

now i implement both the interfaces in a single class

Class A:Interface1,Interface2
{
}

now according to my searchings i found that we can implement both the interfaces in the following manner

Class A:Interface1,Interface2
{
public string Interface1.ReturnString1()
{
return "Interface1.ReturnString1";
}
public string Interface2.ReturnString1()
{
return "Interface2.ReturnString1";
}
}

but on compiling it is giving an error:"the modifier public is not valid for this item"

after i remove public and then i compile the code, it compiles successfully
but i'm not able to access these methods by creating an object of the class.


Can anyone solve this problem

Amit More (CMC)


-- modified at 3:01 Wednesday 6th June, 2007

Amit More (CMC)
AnswerRe: A typical case about interfaces Pin
Christian Graus5-Jun-07 20:50
protectorChristian Graus5-Jun-07 20:50 
GeneralRe: A typical case about interfaces Pin
Manoj Kumar Rai5-Jun-07 21:01
professionalManoj Kumar Rai5-Jun-07 21:01 
GeneralRe: A typical case about interfaces Pin
originSH5-Jun-07 22:27
originSH5-Jun-07 22:27 
GeneralRe: A typical case about interfaces Pin
originSH5-Jun-07 22:30
originSH5-Jun-07 22:30 
AnswerRe: A typical case about interfaces Pin
Manoj Kumar Rai5-Jun-07 21:00
professionalManoj Kumar Rai5-Jun-07 21:00 
GeneralRe: A typical case about interfaces [modified] Pin
amitcoder835-Jun-07 21:05
amitcoder835-Jun-07 21:05 
GeneralRe: A typical case about interfaces Pin
Manoj Kumar Rai5-Jun-07 21:10
professionalManoj Kumar Rai5-Jun-07 21:10 
GeneralRe: A typical case about interfaces Pin
amitcoder835-Jun-07 21:16
amitcoder835-Jun-07 21:16 
GeneralRe: A typical case about interfaces Pin
Manoj Kumar Rai5-Jun-07 21:27
professionalManoj Kumar Rai5-Jun-07 21:27 
GeneralRe: A typical case about interfaces Pin
amitcoder835-Jun-07 21:32
amitcoder835-Jun-07 21:32 
QuestionPlease Help Pin
codingrocks5-Jun-07 20:07
codingrocks5-Jun-07 20:07 
AnswerRe: Please Help Pin
Christian Graus5-Jun-07 20:14
protectorChristian Graus5-Jun-07 20:14 
General[Message Deleted] Pin
codingrocks5-Jun-07 20:25
codingrocks5-Jun-07 20:25 
GeneralRe: To bind a value from DataGridView to textbox Pin
Christian Graus5-Jun-07 20:43
protectorChristian Graus5-Jun-07 20:43 
GeneralRe: To bind a value from DataGridView to textbox Pin
Manoj Kumar Rai5-Jun-07 20:46
professionalManoj Kumar Rai5-Jun-07 20:46 
GeneralRe: To get a selected value from datagrid view Pin
Manoj Kumar Rai5-Jun-07 21:06
professionalManoj Kumar Rai5-Jun-07 21:06 
GeneralRe: To get a selected value from datagrid view Pin
codingrocks5-Jun-07 21:12
codingrocks5-Jun-07 21:12 

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.