HELP! ActiveX controls in dialog box 
Author Message
 HELP! ActiveX controls in dialog box

Win95: MSDEV 5.0

I have two dialog boxes in different projects.
Both have the Calendar OCX embedded.
For both I used Class Wizard to create a variable for the Calendar, inside
my Dialog class.

One works, the other does not display.

This is due to
CDialog::DoModal()
     CreateDlgIndirect(lpDialogTemplate, CWnd::FromHandle(hWndParent),
hInst)
this function returns false.

When I remove the Calendar OCX and comment out the variable, the Dialog box
displays itself.
I've started from scratch 3 times now, and it KEEPS DOING IT!!!!!

Any ideas as to why?

Steve Hobley



Mon, 02 Oct 2000 03:00:00 GMT  
 HELP! ActiveX controls in dialog box

Quote:

> Win95: MSDEV 5.0

> I have two dialog boxes in different projects.
> Both have the Calendar OCX embedded.
> For both I used Class Wizard to create a variable for the Calendar, inside
> my Dialog class.

> One works, the other does not display.

> This is due to
> CDialog::DoModal()
>      CreateDlgIndirect(lpDialogTemplate, CWnd::FromHandle(hWndParent),
> hInst)
> this function returns false.

> When I remove the Calendar OCX and comment out the variable, the Dialog box
> displays itself.
> I've started from scratch 3 times now, and it KEEPS DOING IT!!!!!

> Any ideas as to why?

> Steve Hobley

did you forget to do AfxEnableControlContainer()
in your InitInstance() method?

Zemin



Mon, 02 Oct 2000 03:00:00 GMT  
 HELP! ActiveX controls in dialog box

Did you find an answer for this yet?  I have a similar problem (but for me I
could never get it to work)...

    Thanks


Quote:
>Win95: MSDEV 5.0

>I have two dialog boxes in different projects.
>Both have the Calendar OCX embedded.
>For both I used Class Wizard to create a variable for the Calendar, inside
>my Dialog class.

>One works, the other does not display.

>This is due to
>CDialog::DoModal()
>     CreateDlgIndirect(lpDialogTemplate, CWnd::FromHandle(hWndParent),
>hInst)
>this function returns false.

>When I remove the Calendar OCX and comment out the variable, the Dialog box
>displays itself.
>I've started from scratch 3 times now, and it KEEPS DOING IT!!!!!

>Any ideas as to why?

>Steve Hobley



Tue, 03 Oct 2000 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. HELP: activex control in dialog box in mfc user dll (dialog not launching)

2. ATL ActiveX Composite Control WITHOUT a dialog box?

3. Cannot add an ActiveX control to a DLL dialog box

4. ActiveX Control in Dialog Box

5. ActiveX control from dialog box in DLL?

6. Assertion in wincore.cpp when I close a dialog box having Activex controls

7. How do you add an ActiveX control to a dialog box

8. Tab order in dialog box with any activeX control

9. Getting events from an ActiveX control not in a dialog box

10. Launching dialog box with ActiveX Control...

11. Using ActiveX controls on dialog boxes?

12. Cannot add an ActiveX control to a DLL dialog box

 

 
Powered by phpBB® Forum Software