Click here to Skip to main content
15,894,291 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to use simple c++ console app in C# Pin
Stefan Troschuetz3-Apr-06 23:43
Stefan Troschuetz3-Apr-06 23:43 
GeneralRe: How to use simple c++ console app in C# Pin
Dan Neely4-Apr-06 2:10
Dan Neely4-Apr-06 2:10 
AnswerRe: How to use simple c++ console app in C# Pin
Vasudevan Deepak Kumar4-Apr-06 5:10
Vasudevan Deepak Kumar4-Apr-06 5:10 
GeneralRe: How to use simple c++ console app in C# Pin
Expert Coming4-Apr-06 20:42
Expert Coming4-Apr-06 20:42 
Questionhow to download directx 9.0 SDK for framework 1.0 ? Pin
hdv2123-Apr-06 20:59
hdv2123-Apr-06 20:59 
AnswerRe: how to download directx 9.0 SDK for framework 1.0 ? Pin
leppie4-Apr-06 0:37
leppie4-Apr-06 0:37 
AnswerRe: how to download directx 9.0 SDK for framework 1.0 ? Pin
Vasudevan Deepak Kumar4-Apr-06 5:11
Vasudevan Deepak Kumar4-Apr-06 5:11 
QuestionBase Class or common static method? Pin
moazzamahmed3-Apr-06 20:05
moazzamahmed3-Apr-06 20:05 
I cant figure out when to use base classes and when to use common
methods that just take in different parameters and do the same task,
instead of having 1 method for each of my objects.

ok so in my data layer (3-tier enterprise web solution), I have
4 classes: mygets, myinserts, mydeletes, myupdates.

Each of these hit the database and do the appropriate work for
7 of my tables: tb1, tb2, tb3 ... tb7

mygets has these methods gettb1(tb1key), getAlltb1, gettb2(tb2key), getAlltb2 ... tb7
each returns a dataset

myinserts takes all fields for tables (as sql parameters) and adds them:
addtb1(field1, field2 ... ), addtb2(field1, field2, ... ) etc.

same for myupdates and mydeletes.

whats the best way to structure having to code the least, and have it
consistent: base classes which have the common functions for each of these 4?
or static methods that basically take in different parameters and get the same
stuff done?

which is more efficient?

related question: are base classes just a better "location" to put common
methods that can be used by a lot of classes? classes that derive from them?

thanks

M

-- modified at 2:09 Tuesday 4th April, 2006
AnswerRe: Base Class or common static method? Pin
Maqsood Ahmed3-Apr-06 20:38
Maqsood Ahmed3-Apr-06 20:38 
GeneralRe: Base Class or common static method? Pin
moazzamahmed4-Apr-06 6:11
moazzamahmed4-Apr-06 6:11 
AnswerRe: Base Class or common static method? Pin
Nicholas Butler3-Apr-06 22:07
sitebuilderNicholas Butler3-Apr-06 22:07 
GeneralRe: Base Class or common static method? Pin
Maqsood Ahmed4-Apr-06 2:04
Maqsood Ahmed4-Apr-06 2:04 
Question----how can I recieve a custom message sent from COM server to C# client? Pin
dragooooon lee3-Apr-06 19:40
dragooooon lee3-Apr-06 19:40 
QuestionCommandBuilder.DeriveParameters Pin
ShivT3-Apr-06 19:11
ShivT3-Apr-06 19:11 
Questionblinking form Pin
Yulianto.3-Apr-06 14:23
Yulianto.3-Apr-06 14:23 
AnswerRe: blinking form Pin
Igor Sukhov3-Apr-06 14:39
Igor Sukhov3-Apr-06 14:39 
AnswerRe: blinking form Pin
Sean893-Apr-06 15:57
Sean893-Apr-06 15:57 
QuestionErrors compiling... Pin
KORCARI3-Apr-06 11:50
KORCARI3-Apr-06 11:50 
GeneralRe: Errors compiling... Pin
Guffa3-Apr-06 12:00
Guffa3-Apr-06 12:00 
GeneralRe: Errors compiling... Pin
Colin Angus Mackay3-Apr-06 12:27
Colin Angus Mackay3-Apr-06 12:27 
JokeRe: Errors compiling... Pin
Guffa3-Apr-06 12:53
Guffa3-Apr-06 12:53 
GeneralRe: Errors compiling... Pin
Colin Angus Mackay3-Apr-06 12:56
Colin Angus Mackay3-Apr-06 12:56 
AnswerRe: Errors compiling... Pin
Christian Graus3-Apr-06 15:10
protectorChristian Graus3-Apr-06 15:10 
AnswerRe: Errors compiling... Pin
HimaBindu Vejella3-Apr-06 20:25
HimaBindu Vejella3-Apr-06 20:25 
QuestionCOM and XslCompiledTransform.Load() Pin
ardikus3-Apr-06 11:16
ardikus3-Apr-06 11:16 

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.