我定义了一个文档类,在视图中引用,
void CNewFarmerView::OnUpdate(CView* pSender, LPARAM lHint, CObject* pHint) 
{
// TODO: Add your specialized code here and/or call the base class
 CFarmerDoc *pDoc=GetDocument();
     pDoc->InitData();  
     m_edtCardNum.SetWindowText("ksdjfkl");   // pDoc->m_longCardNum;
    
   // return TRUE;

}但是编译是发生如下错误,我的CFarmerDco是继承CDocument的类。请高手给一个解决方法。
E:\Farmprj\NewFarmerView.cpp(96) : error C2440: 'initializing' : cannot convert from 'class CDocument *' to 'class CFarmerDoc *'
        Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
Error executing cl.exe.