broc
October 17th, 1999, 07:33 PM
hi,
i need to disable "OK" button of a propertysheet and i don't know how to do this .
i tried something like this :
...
int CALLBACK PropSheetProc(
HWND hwndDlg, // handle to the property sheet dialog box
UINT uMsg, // message identifier
LPARAM lParam // message parameter
)
{
((CButton *)::GetDlgItem(hwndDlg,IDOK))->EnableWindow(FALSE);
return 1;
}
...
void MySettings()
{
...
m_propsheet=new CPropertySheet(_T("My propertysheet"));
m_propsheet->m_psh.dwSize=sizeof ( PROPSHEETHEADER );
m_propsheet->m_psh.dwFlags|=PSP_USECALLBACK;
m_propsheet->m_psh.pfnCallback=PropSheetProc;
m_propsheetSession->DoModal();
...
}
...
but it not work .
thanks in advance for your help .
i need to disable "OK" button of a propertysheet and i don't know how to do this .
i tried something like this :
...
int CALLBACK PropSheetProc(
HWND hwndDlg, // handle to the property sheet dialog box
UINT uMsg, // message identifier
LPARAM lParam // message parameter
)
{
((CButton *)::GetDlgItem(hwndDlg,IDOK))->EnableWindow(FALSE);
return 1;
}
...
void MySettings()
{
...
m_propsheet=new CPropertySheet(_T("My propertysheet"));
m_propsheet->m_psh.dwSize=sizeof ( PROPSHEETHEADER );
m_propsheet->m_psh.dwFlags|=PSP_USECALLBACK;
m_propsheet->m_psh.pfnCallback=PropSheetProc;
m_propsheetSession->DoModal();
...
}
...
but it not work .
thanks in advance for your help .