I have a static text named IDC_STATIC for which I made a click event, but it is not getting called when it's clicked.
ON_BN_CLICKED(IDC_STATIC, ontest) //(begin message map)
void test::ontest(my method)
{
MessageBox("success");
}
afx_msg void test(); //(header file)
What is wrong with the code?
The solution is to go to the static text control's properties and enable Notify.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With