请教一个简单问题,请各位指教阿

Developerljm 2003-10-16 02:23:17
我现在遇到这样一个问题,当在对话框中放入CRichEditCtrl时,对话框就无法打开(CDialog::DoModal()),返回结果为-1。

请各位指教阿,能给解释一下也行阿,等待....
...全文
29 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
Developerljm 2003-10-16
  • 打赏
  • 举报
回复
但是这句话——If you use rich edit via CRichEditCtrl, CRichEditView, or CRichEditDoc, you don't need to call this function.

不太理解。
Developerljm 2003-10-16
  • 打赏
  • 举报
回复
AfxInitRichEdit
BOOL AFXAPI AfxInitRichEdit( );

Remarks

Call this function to initialize the rich edit control for the application. It will also initialize the common controls library, if the library hasn’t already been initialized for the process. If you use the rich edit control directly from your MFC application, you should call this function to assure that MFC has properly initialized the rich edit control runtime. If you use rich edit via CRichEditCtrl, CRichEditView, or CRichEditDoc, you don't need to call this function.
Developerljm 2003-10-16
  • 打赏
  • 举报
回复
调用这个函数是对的afxricheditInit,但是为什么呢?
flyelf 2003-10-16
  • 打赏
  • 举报
回复
在CxxxApp::InitInstance中添加AfxInitRichEdit();
wuxfBrave 2003-10-16
  • 打赏
  • 举报
回复
在app的initinstance中加入afxricheditInit()初始化richedit
microran2000 2003-10-16
  • 打赏
  • 举报
回复
是否需要添加InitCommonControl函数.一般这个问题出在WM_InitDialog消息处理或者成员变量的动态绑定和消息映射上.

15,979

社区成员

发帖
与我相关
我的任务
社区描述
VC/MFC 界面
社区管理员
  • 界面
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧