Do not use the C++ delete operator to destroy a frame window. Use CWnd::DestroyWindow instead自己New的MFC基础类的对象//自己负责释放?有系统帮你释放的吗?
解决方案 »
- 请高手指点:要在主界面和界面上一对话框同时显示波形,怎么处理?有什么好的办法没?
- 如何获得Month calendar控件中选取的日期
- 急!!在线等!怎样通过VC调用DCOM服务的问题?请各位大侠指点!谢谢!
- 100分 求助:“无窗口” 的消息问题
- sdk里怎样使模板的类型转换成字符型?急等~~~~~~~~~~~~~
- 马上就是我的生日了
- 求如何由ip得到对方的操作系统是什么版本的代码
- 请问如何在程序运行时,将某个目录底下的一个bmp文件,显示在一个CListCtl中
- 我现在要做一个发送和接受email的程序,而且还要能发送附件,那位朋友有这方面的经验!
- 求救一个TOOLBOX的小问题
- 关于SetupDiGetDeviceRegistryProperty()函数问题
- 为什么请求一个网址返回了压缩内容?
必须有实际的窗口创建了(Create,LoadFrame),在窗口关闭的消息响应时调用PostNcDestroy自动删除
MDI客户窗口与主框架窗口什么区别???
函数里是
m_sConnectSocket.Create();
m_sConnectSocket.Connect(m_strServName,m_strServPort2);//如果连接成功,会触发系统调用重新的写的虚函数OnConnect函数把
{
// default for frame windows is to allocate them on the heap
// the default post-cleanup is to 'delete this'.
// never explicitly call 'delete' on a CFrameWnd, use DestroyWindow instead
delete this;
}
PostNcDestroy里帮你做了delete操作了,所以你不需要delete了