Click here to Skip to main content
15,907,328 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Can not print in Landscape Mode Pin
ATC20-Apr-03 5:34
ATC20-Apr-03 5:34 
GeneralRe: With your helps, it works now! Pin
ATC22-Apr-03 9:03
ATC22-Apr-03 9:03 
GeneralSplitterWnd - Moving the bar Pin
Shutter19-Apr-03 5:26
Shutter19-Apr-03 5:26 
GeneralQuestion about const pointer. Pin
George219-Apr-03 4:04
George219-Apr-03 4:04 
GeneralRe: Question about const pointer. Pin
John M. Drescher19-Apr-03 5:01
John M. Drescher19-Apr-03 5:01 
GeneralRe: Question about const pointer. Pin
George219-Apr-03 18:17
George219-Apr-03 18:17 
GeneralRe: Question about const pointer. Pin
Phil Hamer19-Apr-03 16:44
Phil Hamer19-Apr-03 16:44 
GeneralRe: Question about const pointer. Pin
George219-Apr-03 18:19
George219-Apr-03 18:19 
GeneralModeless Dialog to back and taskbar button Pin
Mathias S.19-Apr-03 2:07
Mathias S.19-Apr-03 2:07 
GeneralRe: Modeless Dialog to back and taskbar button Pin
John M. Drescher19-Apr-03 3:46
John M. Drescher19-Apr-03 3:46 
GeneralRe: Modeless Dialog to back and taskbar button Pin
Michael Dunn19-Apr-03 5:19
sitebuilderMichael Dunn19-Apr-03 5:19 
GeneralWorker-Thread in Win32 Application Pin
ZarrinPour19-Apr-03 1:16
ZarrinPour19-Apr-03 1:16 
GeneralRe: Worker-Thread in Win32 Application Pin
Bartosz Bien19-Apr-03 1:32
Bartosz Bien19-Apr-03 1:32 
GeneralRe: Worker-Thread in Win32 Application Pin
Joe Woodbury19-Apr-03 5:28
professionalJoe Woodbury19-Apr-03 5:28 
GeneralRe: Worker-Thread in Win32 Application Pin
Bartosz Bien19-Apr-03 5:36
Bartosz Bien19-Apr-03 5:36 
QuestionHow To Close All Documents in MDI Pin
Vikrant Vikrant19-Apr-03 1:14
Vikrant Vikrant19-Apr-03 1:14 
AnswerRe: How To Close All Documents in MDI Pin
Bartosz Bien19-Apr-03 1:28
Bartosz Bien19-Apr-03 1:28 
GeneralExplicit Linking problem Pin
Cyberizen19-Apr-03 1:02
Cyberizen19-Apr-03 1:02 
GeneralRe: Explicit Linking problem Pin
Gary R. Wheeler19-Apr-03 3:08
Gary R. Wheeler19-Apr-03 3:08 
Generalpragma once Pin
John-theKing18-Apr-03 23:14
John-theKing18-Apr-03 23:14 
GeneralRe: pragma once Pin
Taka Muraoka18-Apr-03 23:19
Taka Muraoka18-Apr-03 23:19 
GeneralRe: pragma once Pin
peterchen19-Apr-03 0:25
peterchen19-Apr-03 0:25 
GeneralDeriving my own base dialog Pin
socceroli18-Apr-03 22:54
socceroli18-Apr-03 22:54 
I want to use my own dialog as a base for another one. Don't want to copy anything from the base dialog, just construct it and ready.
Someone confuses me by advising I have to add/change a constructor. I tried his way (adding UINT nId) as good as I've understood him. But seems to be not good enough. I think I'm making mistakes with the dialog id. I was told to remove the "enum {IDD...}" line. I don't understand.
What do I have to do in my base dialog and what in the derivated dialog (.h + .cpp)?

This is my code which does NOT construct the derivated dialog:

***MyBaseDlg.h***
// Two constructors
CMyBaseDlg (CWnd* pParent = NULL); // Not used by the derivated Dialog
CMyBaseDlg (UINT nIDTemplate, CWnd* pParent = NULL); // Use this one


*** MyBaseDlg.cpp***
CMyBaseDlg:: CMyBaseDlg (CWnd* pParent /*=NULL*/)
: CDialog(CMyBaseDlg::IDD, pParent)
{
}

CMyBaseDlg:: CMyBaseDlg (UINT nIDTemplate, CWnd* pParent /*=NULL*/)
: CDialog(nIDTemplate, pParent)
{
}


Derivated Dialog: class CSecondDlg : public CMyBaseDlg

***SecondDlg.h***
CSecondDlg(UINT nID, CWnd* pParent = NULL);

***SecondDlg.cpp***
CSecondDlg:: CSecondDlg (UINT nIDD, CWnd* pParent /*=NULL*/)
: CMyBaseDlg (nIDD, pParent)
{
}


Call the derivated dialog somewhere in my code:
CSecondDlg dlg(CMyBaseDlg::IDD); // How to call correctly?

Thanks,
OMG | :OMG: Oli

GeneralRe: Deriving my own base dialog Pin
Bartosz Bien19-Apr-03 1:43
Bartosz Bien19-Apr-03 1:43 
GeneralGetDecryptionExponent in Crypto++ Pin
DREVET Olivier18-Apr-03 22:52
DREVET Olivier18-Apr-03 22:52 

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.