manual Control Messages in MFC

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: BrownViper (BrownViper_at_discussions.microsoft.com)
Date: 12/02/04


Date: Thu, 2 Dec 2004 08:07:09 -0800

I m sure someone done this before

my CFormView derived class has a few checkboxes.
I want to force the message handlers of all the checkboxes to be called when
I change (check/uncheck) one of them. I dont want to use the group thing.
my code is like this
CMyFormView::OnCheck1()
{
m_bStatusCode = ((CButton *)(GetDlgItem( IDC_CHECK_COMPILE_CODE
)))->GetCheck() ? TRUE : FALSE;

m_MyGUI = COMPILE_CODE;
/* needs to send the notify the parent to execute the other message
handlers*/
}
CMyFormView::OnCheck2()
{
m_bStatusAssets = ((CButton *)(GetDlgItem( IDC_CHECK_BUILD_ASSETS
)))->GetCheck() ? TRUE : FALSE;
if(m_MyGUI == COMPLE_CODE)
{
     /* do something */
}

...
....
......

Is this possible?

Regards
Viper


Quantcast