In which part of my code do I test whether a check box has been clicked ?
Here's some of my code:
Code:
// my own two functions:
bool CheckBox(HWND hDlg, HWND button)
{
if( SendMessage(hDlg, BM_GETCHECK, 0, 0) == BST_CHECKED )
{
return TRUE;
}
else
{
return FALSE;
}
}
void MakeActive(HWND hDlg, HWND winone, HWND wintwo)
{
EnableWindow(winone, TRUE);
EnableWindow(wintwo, TRUE);
}
// the code to test the check box:
if(CheckBox(hDlg, mon_check) == TRUE)
{
MakeActive(hDlg, mon_one, mon_two);
}
Thanks heaps