I am having problems setting up that a specified dialog is displayed before any others 
Author Message
 I am having problems setting up that a specified dialog is displayed before any others

I have put the necessary code to display a dialog in the derived
CWinApp::InitInstance method so that it is the first dialog that appears but
I am getting errors:  for this code
CMessageDlg dlgMessage(this);
dlgMessage.DoModal();

when I have a "this" in the bracket I get this error:
cannot convert parameter 1 from 'class CAmviaExamApp *const ' to 'class CWnd
*'

when I leave out the "this" I get this error:
error C2228: left of '.DoModal' must have class/struct/union type

what can I do



Sat, 05 Mar 2005 07:17:48 GMT  
 I am having problems setting up that a specified dialog is displayed before any others
How about:

CMessageDlg dlgMessage();

or

CMessageDlg dlgMessage;

TFM3

Note: Spam-resistant e-mail address


Quote:
> I have put the necessary code to display a dialog in the derived
> CWinApp::InitInstance method so that it is the first dialog that appears
but
> I am getting errors:  for this code
> CMessageDlg dlgMessage(this);
> dlgMessage.DoModal();

> when I have a "this" in the bracket I get this error:
> cannot convert parameter 1 from 'class CAmviaExamApp *const ' to 'class
CWnd
> *'

> when I leave out the "this" I get this error:
> error C2228: left of '.DoModal' must have class/struct/union type

> what can I do



Sat, 05 Mar 2005 07:47:39 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. HELP, I am having problems with pointer...

2. I am having problems with MFC42.dll file

3. i am unable to read from a file having 26ascii character(ctrl+z)

4. I am having with my bishop

5. I am having troubles with the switch()

6. I am new to programming and am lost

7. I am having probability d

8. I am having probability difficulties...HELP

9. I am trying to display a bitmap

10. Setzen Papierformaten am Drucker / Setting of Paperformats on Printer

11. Setzen Papierformaten am Drucker / Setting of Paperformats on Printer

12. Customizing Open File Dialog -- am I right?

 

 
Powered by phpBB® Forum Software