Click here to Skip to main content
15,916,215 members
Home / Discussions / C#
   

C#

 
QuestionHow to configure to OpenOffice through C# Pin
pashitech18-Oct-07 19:15
pashitech18-Oct-07 19:15 
QuestionHow to set entry point for an class [modified] Pin
Exelioindia18-Oct-07 19:11
Exelioindia18-Oct-07 19:11 
AnswerRe: How to set entry point for an class Pin
N a v a n e e t h18-Oct-07 19:26
N a v a n e e t h18-Oct-07 19:26 
Questionclasses inheritance Pin
kabutar18-Oct-07 18:54
kabutar18-Oct-07 18:54 
AnswerRe: classes inheritance Pin
N a v a n e e t h18-Oct-07 19:24
N a v a n e e t h18-Oct-07 19:24 
GeneralRe: classes inheritance Pin
kabutar18-Oct-07 19:38
kabutar18-Oct-07 19:38 
GeneralRe: classes inheritance Pin
N a v a n e e t h18-Oct-07 19:50
N a v a n e e t h18-Oct-07 19:50 
GeneralRe: classes inheritance Pin
Malcolm Smart18-Oct-07 21:23
Malcolm Smart18-Oct-07 21:23 
It also lets you store a collection of 'Animals' in a collection without having to have a collecton of dogs, a collection of cats, a collection of llamas, a collection of...I think you know where I am going.

You can just have a collection of Animals, and add any class dervied from Animal to it.

class Animal {};
class Cat : Animal {};
class Dog : Animal {};

List<Animal>_myListOfAnimals = new List<Animal>();

Animal myCat = new Cat(); //assume Cat derived from Animal
Animal myDog = new Dog(); //assume Dog derived from Animal

_myListOfAnimals.Add( myCat );
_myListOfAnimals.Add( myDog );


Saying this, if you are using inheritence just to have this ability, then interfaces are the way to go.




"More functions should disregard input values and just return 12. It would make life easier." - comment posted on WTF


"This time yesterday, I still had 24 hours to meet the deadline I've just missed today."

QuestionHow can I drawing over fullscreen ? Pin
Khoramdin18-Oct-07 18:53
Khoramdin18-Oct-07 18:53 
AnswerRe: How can I drawing over fullscreen ? Pin
Luc Pattyn19-Oct-07 3:18
sitebuilderLuc Pattyn19-Oct-07 3:18 
QuestionHTML PARSER problem Pin
netwearcdz118-Oct-07 17:09
netwearcdz118-Oct-07 17:09 
AnswerRe: HTML PARSER problem Pin
N a v a n e e t h18-Oct-07 18:56
N a v a n e e t h18-Oct-07 18:56 
GeneralRe: HTML PARSER problem Pin
netwearcdz119-Oct-07 9:50
netwearcdz119-Oct-07 9:50 
QuestionHow to position controls in panel dynamically? Pin
K a b u k i18-Oct-07 16:44
K a b u k i18-Oct-07 16:44 
AnswerRe: How to position controls in panel dynamically? Pin
K a b u k i18-Oct-07 19:44
K a b u k i18-Oct-07 19:44 
QuestionColumn Totals of a data grid Pin
uppuluripavan18-Oct-07 10:29
uppuluripavan18-Oct-07 10:29 
AnswerRe: Column Totals of a data grid Pin
Malcolm Smart18-Oct-07 21:44
Malcolm Smart18-Oct-07 21:44 
AnswerRe: Column Totals of a data grid Pin
Nouman Bhatti18-Oct-07 22:05
Nouman Bhatti18-Oct-07 22:05 
QuestionCopy Folder Pin
mehrdadc4818-Oct-07 10:11
mehrdadc4818-Oct-07 10:11 
AnswerRe: Copy Folder Pin
TJoe18-Oct-07 10:26
TJoe18-Oct-07 10:26 
QuestionForm Question Pin
MumbleB18-Oct-07 8:15
MumbleB18-Oct-07 8:15 
AnswerRe: Form Question Pin
Judah Gabriel Himango18-Oct-07 8:24
sponsorJudah Gabriel Himango18-Oct-07 8:24 
AnswerRe: Form Question Pin
Patrick Etc.18-Oct-07 8:26
Patrick Etc.18-Oct-07 8:26 
AnswerRe: Form Question Pin
Abdul Qahhar18-Oct-07 9:11
Abdul Qahhar18-Oct-07 9:11 
GeneralRe: Form Question Pin
Luc Pattyn18-Oct-07 9:21
sitebuilderLuc Pattyn18-Oct-07 9:21 

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.