Click here to Skip to main content
15,913,341 members
Home / Discussions / C#
   

C#

 
GeneralRe: what is happen Pin
Nader Elshehabi28-Nov-06 8:20
Nader Elshehabi28-Nov-06 8:20 
QuestionDatagrid parent children rows??? Pin
Small Rat27-Nov-06 6:21
Small Rat27-Nov-06 6:21 
AnswerRe: Datagrid parent children rows??? Pin
Not Active27-Nov-06 7:40
mentorNot Active27-Nov-06 7:40 
Questionoverload,override,abstract Pin
saravanan0527-Nov-06 5:42
saravanan0527-Nov-06 5:42 
AnswerRe: overload,override,abstract Pin
J4amieC27-Nov-06 5:57
J4amieC27-Nov-06 5:57 
GeneralRe: overload,override,abstract Pin
Eric Dahlvang27-Nov-06 7:22
Eric Dahlvang27-Nov-06 7:22 
GeneralRe: overload,override,abstract Pin
J4amieC28-Nov-06 0:33
J4amieC28-Nov-06 0:33 
AnswerRe: overload,override,abstract Pin
karam chandrabose27-Nov-06 9:20
karam chandrabose27-Nov-06 9:20 
Overloading :
a particular operator / method doing different tasks:
Same method name, Different parameters.
example: method overloading
public void PrintString(String str)
{
Console.WriteLine(str);
}
public void PrintString(int n)
{
Console.Writeline(n.ToString());
}
In the above example PrintString method is overloaded, that is there are two methods that differ by parameter. This is mandatory for overloding, i.e the method parameters must differ. if just the return types differ, the code will not compile. There is no keyword called overload.

Overriding:
If we have a method in our class and feel there is possibility that any class that inherits our class might need to implemt our method in a different way, we have to make our method virtual. Only abstract / virtual methods can be overridden.
public class classa
{
protected virtual void MyMethod()
{
//some code
}
}
public class classb: classa
{
protected override void MyMethod()
{
//slightly different code
}
}
Abstract:
Abstract methods are those that have no implementation, abstarct methods can reside only in abstract classes, and any class which inherits the abstract class "MUST" override the abstract method and give proper implementation.

hope this helped.




Baba thts what they say, B to the A to the B to the A Poke tongue | ;-P
QuestionHow to detect DataGridView Order Change ? Pin
Marcos Hernandez27-Nov-06 5:40
Marcos Hernandez27-Nov-06 5:40 
AnswerRe: How to detect DataGridView Order Change ? Pin
ednrgc28-Nov-06 2:52
ednrgc28-Nov-06 2:52 
GeneralRe: How to detect DataGridView Order Change ? Pin
Marcos Hernandez28-Nov-06 4:00
Marcos Hernandez28-Nov-06 4:00 
GeneralRe: How to detect DataGridView Order Change ? Pin
ednrgc28-Nov-06 4:02
ednrgc28-Nov-06 4:02 
GeneralRe: How to detect DataGridView Order Change ? Pin
Marcos Hernandez28-Nov-06 4:11
Marcos Hernandez28-Nov-06 4:11 
GeneralRe: How to detect DataGridView Order Change ? Pin
ednrgc28-Nov-06 4:12
ednrgc28-Nov-06 4:12 
GeneralRe: How to detect DataGridView Order Change ? Pin
Marcos Hernandez28-Nov-06 4:29
Marcos Hernandez28-Nov-06 4:29 
GeneralRe: How to detect DataGridView Order Change ? Pin
ednrgc28-Nov-06 4:35
ednrgc28-Nov-06 4:35 
GeneralRe: How to detect DataGridView Order Change ? Pin
Marcos Hernandez28-Nov-06 4:59
Marcos Hernandez28-Nov-06 4:59 
GeneralRe: How to detect DataGridView Order Change ? Pin
ednrgc28-Nov-06 5:34
ednrgc28-Nov-06 5:34 
GeneralRe: How to detect DataGridView Order Change ? Pin
Marcos Hernandez28-Nov-06 5:37
Marcos Hernandez28-Nov-06 5:37 
Questionlistview item check problem Pin
numbers1thru927-Nov-06 4:59
numbers1thru927-Nov-06 4:59 
AnswerRe: listview item check problem Pin
albCode27-Nov-06 5:05
albCode27-Nov-06 5:05 
GeneralRe: listview item check problem Pin
numbers1thru927-Nov-06 5:40
numbers1thru927-Nov-06 5:40 
Questionadding \n to a string Pin
Bhupesh Dev27-Nov-06 4:13
Bhupesh Dev27-Nov-06 4:13 
AnswerRe: adding \n to a string Pin
Stefan Troschuetz27-Nov-06 4:19
Stefan Troschuetz27-Nov-06 4:19 
AnswerRe: adding \n to a string Pin
albCode27-Nov-06 4:27
albCode27-Nov-06 4:27 

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.