我看<<Programming Windows with MFC>>, 中关于"using ActiveX Controls in Nondialog Windows",有一段:Here's how to add the MFC calendar control to a view:
1.Insert the control into the project. Name the wrapper class CCalendar.
2.Add a CCalendar member variable named m_ctlCalendar to the view.
3.Add the following statement to the view's OnCreate handler: m_ctlCalendar.Create (NULL, WS_VISIBLE,
CRect (0, 0, 400, 300), this, IDC_CALENDAR); 请问最后一个Create函数的最后一个参数:IDC_CALENDAR 是从哪里获得的,我编译了几次都没有通过. 谢谢.
1.Insert the control into the project. Name the wrapper class CCalendar.
2.Add a CCalendar member variable named m_ctlCalendar to the view.
3.Add the following statement to the view's OnCreate handler: m_ctlCalendar.Create (NULL, WS_VISIBLE,
CRect (0, 0, 400, 300), this, IDC_CALENDAR); 请问最后一个Create函数的最后一个参数:IDC_CALENDAR 是从哪里获得的,我编译了几次都没有通过. 谢谢.
如果你要自创一个控件,就得手工在这个。h文件里加一个控件ID
可以直接在。h中添加,也可以在VIEW菜单中的resource symbols里添加。
谢谢.