Click here to Skip to main content
15,914,419 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: DialolgProc doesnt work Pin
Rickard Andersson202-Dec-02 23:14
Rickard Andersson202-Dec-02 23:14 
GeneralRe: DialolgProc doesnt work Pin
Paul M Watt3-Dec-02 5:55
mentorPaul M Watt3-Dec-02 5:55 
GeneralRe: DialolgProc doesnt work Pin
Tili3-Dec-02 21:54
Tili3-Dec-02 21:54 
QuestionWhy can't use CFindReplaceDialog as A Base Class? Pin
zhdleonid2-Dec-02 21:17
zhdleonid2-Dec-02 21:17 
AnswerRe: Why can't use CFindReplaceDialog as A Base Class? Pin
jhwurmbach2-Dec-02 21:35
jhwurmbach2-Dec-02 21:35 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
zhdleonid2-Dec-02 22:02
zhdleonid2-Dec-02 22:02 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
zhdleonid2-Dec-02 23:17
zhdleonid2-Dec-02 23:17 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
jhwurmbach2-Dec-02 23:43
jhwurmbach2-Dec-02 23:43 
zhdleonid wrote:
CMyFindDlg dlg; // i want to declare the Class CMyFindDlg object

First, MSDN says: "CFindReplaceDialog objects are constructed on the heap with the new operator".
Maybe doing so with your class may help?
CMyFindDlg* pDlg = new CMyFindDlg();
Second, you cant make a CMyFindDlg without parameters, because you have no constructor defined that uses no parameters. This is what the compiler is saying here:
": error C2512: 'CMyFindDlg' : no appropriate default constructor available".
Call your constructor with any constructor arguments you need, construct the CFindReplaceDialog without parameters (as you do) and store the parameters in member vars of CMyFindDlg until you need them.

Third, as the MSDN states in the article about CFindReplaceDialog,
you show the dialog using the Create()-function.
Do this when calling your dialog (and override this function as neccesary).

Hope this helps


--
"My opinions may have changed, but not the fact that I am right."
Found in the sig of Herbert Kaminski
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
zhdleonid3-Dec-02 0:49
zhdleonid3-Dec-02 0:49 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
jhwurmbach3-Dec-02 1:24
jhwurmbach3-Dec-02 1:24 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
zhdleonid3-Dec-02 2:40
zhdleonid3-Dec-02 2:40 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
Christian Graus2-Dec-02 23:43
protectorChristian Graus2-Dec-02 23:43 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
zhdleonid3-Dec-02 0:52
zhdleonid3-Dec-02 0:52 
GeneralRe: Why can't use CFindReplaceDialog as A Base Class? Pin
Christian Graus3-Dec-02 10:29
protectorChristian Graus3-Dec-02 10:29 
GeneralCopyright sign © in about box Pin
Geert Delmeiren2-Dec-02 20:28
Geert Delmeiren2-Dec-02 20:28 
GeneralRe: Copyright sign © in about box Pin
Rickard Andersson202-Dec-02 21:35
Rickard Andersson202-Dec-02 21:35 
GeneralRe: Copyright sign © in about box Pin
Geert Delmeiren2-Dec-02 23:09
Geert Delmeiren2-Dec-02 23:09 
GeneralRe: Copyright sign © in about box Pin
Anonymous3-Dec-02 2:49
Anonymous3-Dec-02 2:49 
GeneralRe: Copyright sign © in about box Pin
Geert Delmeiren3-Dec-02 20:24
Geert Delmeiren3-Dec-02 20:24 
GeneralDialogBase Program with no TaskBar Button. Pin
Behzad Ebrahimi2-Dec-02 20:07
Behzad Ebrahimi2-Dec-02 20:07 
GeneralRe: DialogBase Program with no TaskBar Button. Pin
Kannan Kalyanaraman2-Dec-02 20:15
Kannan Kalyanaraman2-Dec-02 20:15 
Generalcannot execute script using IHTMLWindow2 Pin
yourbuddy772-Dec-02 17:23
yourbuddy772-Dec-02 17:23 
GeneralOLE Containers Pin
vijayaramaraju2-Dec-02 17:11
vijayaramaraju2-Dec-02 17:11 
GeneralOLE Containers Pin
vijayaramaraju2-Dec-02 17:10
vijayaramaraju2-Dec-02 17:10 
GeneralCombo Box drop-down list problem Pin
IGx892-Dec-02 14:49
IGx892-Dec-02 14:49 

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.