目的:左面板用作控制,是个对话框,继承自CFormView
      右面板用于显示图形。
采用的是单文档程序。
问题:右面板应该继承自哪个类?应该单独创建一个文件吗?BOOL CMainFrame::OnCreateClient(LPCREATESTRUCT lpcs, CCreateContext* pContext) 
{
// TODO: Add your specialized code here and/or call the base class
if(!m_wndSplitter.CreateStatic(this,1,2,WS_CHILD|WS_VISIBLE))
{
TRACE("Failed to createstaticSplitter\n");
return FALSE;
}
if(!m_wndSplitter.CreateView(0,0,RUNTIME_CLASS(CFormCommandView),
CSize(200,160),pContext))
{
TRACE("FAILED TO CREATE COMMAND VIEW PANE\n");
return FALSE; }
if(!m_wndSplitter.CreateView(0,1,RUNTIME_CLASS(CRenderView),CSize(200,160),
pContext))
{
TRACE("Failed to create preview pane\n");
return FALSE;
}
return TRUE;

}其中的CRenderView在MainFrm.h中是这样声明的
class CRenderView: public CView
{
};
运行时候说违背了assertion。
原因可能在哪里,朋友们可要知无不言啊,谢谢了。