编程时出现如下错误: error C2065: 'OnNum' : undeclared identifier
error C2440: 'type cast' : cannot convert from 'int *' to 'void (__thiscall CCmdTarget::*)(unsigned int)'
不知道如何解决?部分代码如下:
afx_msg void OnNum(UINT uID);
ON_CONTROL_RANGE(BN_CLICKED,IDC_NUM_0,IDC_NUM_9,OnNum)
void CCalculatorDlg::OnNum(UINT uID)
{
UINT index=uID-IDC_NUM_0;
CString num;
num.Format(_T("%d"),index);
AfxMessageBox(num);
}