Click here to Skip to main content
15,921,156 members
Home / Discussions / C#
   

C#

 
GeneralRe: Stupid question of the day (Trees) Pin
martin_hughes2-Apr-08 3:27
martin_hughes2-Apr-08 3:27 
GeneralRe: Stupid question of the day (Trees) Pin
ChrisKo2-Apr-08 5:41
ChrisKo2-Apr-08 5:41 
QuestionSimple question confused ! Pin
Krazy Programmer2-Apr-08 2:20
Krazy Programmer2-Apr-08 2:20 
GeneralRe: Simple question confused ! Pin
LongRange.Shooter2-Apr-08 4:01
LongRange.Shooter2-Apr-08 4:01 
GeneralRe: Simple question confused ! Pin
Krazy Programmer2-Apr-08 7:12
Krazy Programmer2-Apr-08 7:12 
GeneralMake a method return different types/classes depending on in-parameters Pin
arnold_w2-Apr-08 2:04
arnold_w2-Apr-08 2:04 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
papadimitriou2-Apr-08 3:34
papadimitriou2-Apr-08 3:34 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
Rob Philpott2-Apr-08 4:01
Rob Philpott2-Apr-08 4:01 
Well, C# only supports function overloading by parameters not return type (which incidentally is not the case for .NET overall) so you either need to create a different named function for each type which is probably useless for what you're trying to do or make your function return an object.

Everything is an object you see, then you can downcast it to whatever you want later. The as keyword is good for this (with reference types).

Regards,
Rob Philpott.

GeneralRe: Make a method return different types/classes depending on in-parameters Pin
arnold_w2-Apr-08 4:08
arnold_w2-Apr-08 4:08 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
Bekjong2-Apr-08 5:22
Bekjong2-Apr-08 5:22 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
led mike2-Apr-08 5:48
led mike2-Apr-08 5:48 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
Pete O'Hanlon2-Apr-08 10:13
mvePete O'Hanlon2-Apr-08 10:13 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
MidwestLimey2-Apr-08 11:38
professionalMidwestLimey2-Apr-08 11:38 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
Pete O'Hanlon2-Apr-08 22:32
mvePete O'Hanlon2-Apr-08 22:32 
GeneralRe: Make a method return different types/classes depending on in-parameters Pin
arnold_w3-Apr-08 1:17
arnold_w3-Apr-08 1:17 
GeneralC# HTTP request/response Pin
George_George2-Apr-08 2:02
George_George2-Apr-08 2:02 
GeneralCrystal reports how to suppress a section programmatically Pin
NewToAspDotNet2-Apr-08 1:49
NewToAspDotNet2-Apr-08 1:49 
QuestionHow to deserialize the object saved in project1 in another assembly project2? Pin
Chesnokov Yuriy2-Apr-08 1:41
professionalChesnokov Yuriy2-Apr-08 1:41 
GeneralRe: How to deserialize the object saved in project1 in another assembly project2? Pin
Simon P Stevens2-Apr-08 3:34
Simon P Stevens2-Apr-08 3:34 
GeneralRe: How to deserialize the object saved in project1 in another assembly project2? Pin
Giorgi Dalakishvili2-Apr-08 4:01
mentorGiorgi Dalakishvili2-Apr-08 4:01 
Generalproblem width Advantech PCI-1730 digital IO card [modified] Pin
arturw822-Apr-08 1:14
arturw822-Apr-08 1:14 
GeneralRe: problem width Advantech PCI-1730 digital IO card Pin
Dave Kreskowiak2-Apr-08 3:52
mveDave Kreskowiak2-Apr-08 3:52 
GeneralRe: problem width Advantech PCI-1730 digital IO card Pin
arturw822-Apr-08 4:13
arturw822-Apr-08 4:13 
GeneralRe: problem width Advantech PCI-1730 digital IO card Pin
Dave Kreskowiak2-Apr-08 5:00
mveDave Kreskowiak2-Apr-08 5:00 
Generalcrystal reporting with C# Pin
Faysal2-Apr-08 1:12
Faysal2-Apr-08 1: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.