原帖发错地方了,在这里http://topic.csdn.net/u/20110803/21/614d56c1-fd4f-4294-82d6-b2e775c616b5.html
ON_CONTROL_RANGE(BN_CLICKED, IDD_MAIN_PANEL+1, m_nMaxID, OnItemClick)
因为是动态生成的控件,我不知道有多少个,我规定起始id为IDD_MAIN_PANEL+1,m_nMaxID初始值为IDD_MAIN_PANEL+1,然后每创建一个进行+1,这样会报错,大家说应该怎么写这个范围,先谢谢大家了以下为错误:
--------------------Configuration: FICS - Win32 Debug--------------------
Compiling...
MyMainPanel.cpp
E:\vc\复件 FICS\MyMainPanel.cpp(42) : error C2440: 'type cast' : cannot convert from 'unsigned short CMyMainPanel::*' to 'unsigned short'
        Conversion is a valid standard conversion, which can be performed implicitly or by use of static_cast, C-style cast or function-style cast
E:\vc\复件 FICS\MyMainPanel.cpp(42) : error C2440: 'initializing' : cannot convert from 'void (__thiscall CCmdTarget::*)(void)' to 'unsigned int'
        Conversion is a valid standard conversion, which can be performed implicitly or by use of static_cast, C-style cast or function-style cast
Error executing cl.exe.FICS.exe - 2 error(s), 0 warning(s)