Click here to Skip to main content
15,921,210 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: SQL ? Pin
Hadi Rezaee27-Jul-01 20:45
Hadi Rezaee27-Jul-01 20:45 
GeneralRe: SQL ? Pin
Jamie Nordmeyer27-Jul-01 22:36
Jamie Nordmeyer27-Jul-01 22:36 
GeneralRe: SQL ? Pin
Hadi Rezaee28-Jul-01 18:58
Hadi Rezaee28-Jul-01 18:58 
Generallogging winsock send/receive Pin
Kuniva26-Jul-01 0:30
Kuniva26-Jul-01 0:30 
Generalclass design question Pin
26-Jul-01 0:25
suss26-Jul-01 0:25 
GeneralRe: class design question Pin
Tomasz Sowinski26-Jul-01 2:50
Tomasz Sowinski26-Jul-01 2:50 
GeneralRe: class design question Pin
26-Jul-01 2:58
suss26-Jul-01 2:58 
GeneralRe: class design question Pin
Tomasz Sowinski26-Jul-01 3:09
Tomasz Sowinski26-Jul-01 3:09 
If all you have to initialize in the base class is the filename, create one c'tor with default argument:
// initfile.h
class CInitFile
{
// ...
CInitFile(const char *szFilename = NULL);
// ...
};

// initfile.cpp
CInitFile::CInitFile(const char *szFilename)
{
if (NULL == szFilename)
{
szFilename = INIT_FILENAME;
}
else
{
m_szFilename = szFilename;
}
}

You should also avoid #defining INIT_FILENAME in .h file. If you want derived classes to know this value, create static function in CInitFile.

Tomasz Sowinski -- http://www.shooltz.com
GeneralRe: class design question Pin
26-Jul-01 3:57
suss26-Jul-01 3:57 
GeneralRe: class design question Pin
Tomasz Sowinski26-Jul-01 4:25
Tomasz Sowinski26-Jul-01 4:25 
GeneralRe: class design question Pin
26-Jul-01 6:04
suss26-Jul-01 6:04 
Generalclass design question Pin
26-Jul-01 0:24
suss26-Jul-01 0:24 
Questionwhats wrong here?? Pin
26-Jul-01 0:14
suss26-Jul-01 0:14 
AnswerRe: whats wrong here?? Pin
Steve T26-Jul-01 12:24
Steve T26-Jul-01 12:24 
GeneralOwner Drawn Buttons Pin
Derek Lakin25-Jul-01 23:22
Derek Lakin25-Jul-01 23:22 
GeneralRe: Owner Drawn Buttons Pin
jerry0davis25-Jul-01 23:33
jerry0davis25-Jul-01 23:33 
GeneralRe: Owner Drawn Buttons Pin
Derek Lakin26-Jul-01 1:45
Derek Lakin26-Jul-01 1:45 
GeneralRe: Owner Drawn Buttons Pin
Paolo Messina26-Jul-01 11:37
professionalPaolo Messina26-Jul-01 11:37 
GeneralRe: Owner Drawn Buttons Pin
Derek Lakin26-Jul-01 21:20
Derek Lakin26-Jul-01 21:20 
QuestionECVT() and FCVT()? Pin
Gérald Mercet25-Jul-01 23:11
Gérald Mercet25-Jul-01 23:11 
AnswerRe: ECVT() and FCVT()? Pin
Gerry26-Jul-01 0:12
Gerry26-Jul-01 0:12 
GeneralI need Help - Dialog Box Pin
Leezo25-Jul-01 21:47
Leezo25-Jul-01 21:47 
GeneralRe: I need Help - Dialog Box Pin
Christian Graus26-Jul-01 12:50
protectorChristian Graus26-Jul-01 12:50 
Generaldisplay a value in an EDITBOX Pin
Gérald Mercet25-Jul-01 21:34
Gérald Mercet25-Jul-01 21:34 
GeneralRe: display a value in an EDITBOX Pin
Gerry25-Jul-01 22:22
Gerry25-Jul-01 22:22 

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.