pDocTemplate = new CMultiDocTemplate(
IDR_TEST1TYPE,
RUNTIME_CLASS(CTest1Doc),
RUNTIME_CLASS(CChildFrame), // custom MDI child frame
RUNTIME_CLASS(CTest1View));
AddDocTemplate(pDocTemplate);
这段代码是什么意思,请高手分析!!

解决方案 »

  1.   

    注册文档\视图框架,RUNTIME_CLASS returns a pointer to a CRuntimeClass structure for the class specified by class_name. Only CObject-derived classes declared with DECLARE_DYNAMIC, DECLARE_DYNCREATE, or DECLARE_SERIAL will return pointers to a CRuntimeClass structure.
      

  2.   

    他是vc类动态识别时用到的,是vc6大技术中的一个。看看《深入浅出mfc》就知道了。