Forum
Please
Log In
to post a new message or reply to an existing one. If you are not registered, please
register.
NOTE: Some forums may be read-only if you are not currently subscribed to
our technical support services.
Subject |
Author |
Date |
|
Artur Shingirei
|
Jul 1, 2004 - 10:36 AM
|
I have a problem:Can not to manipulate buttons states(Enable/Disable) at toolbar on child(modeless) dialog At main dialog(Dialog based application) I create a modeless child dialog. Following code create a child dialog.
void CMainDlg::OnButton() { CChildDlg* pDlg = new CChildDlg(); pDlg->Create(....); pDlg->ShowWindow(SW_SHOW); }
This(child) dialog have a toolbar (CChildDlg::CExtToolControlBar m_wndToolBar); I try to manipulate of button states at the toolbar by CCmdUI->Enable(TRUE/FALSE); CChildDlg::OnUpadteButton1(CCmdUI* pCmd) { pCmd->Enable(FALSE); ] But it is not help.
After appearance of ChildDialog, buttons on them is not visible. I add following code and buttons will appear but problem with (Enable/Disable) stayed BOOL CChildDlg::OnInitDialog() { ... CWinApp * pApp = ::AfxGetApp(); VERIFY( g_CmdManager->ProfileWndAdd( pApp->m_pszRegistryKey, this->m_hWnd ) ); }
I have been using Prof-UIS v2.23
|
|
Technical Support
|
Jul 2, 2004 - 1:36 AM
|
Dear Artur,
You need to call the ProfileWndAdd method during initialization of your modeless dialog only if your main dialog is not a parent window of the modeless dialog.
|
|