我通过向导建立了一个类,可提示:mytreeview.h(14) : error C2504: 'CTreeView' : base class undefined
代码:
#if !defined(AFX_MYTREEVIEW_H__10D3CC4C_3F62_42A0_9250_C714D9BF7285__INCLUDED_)
#define AFX_MYTREEVIEW_H__10D3CC4C_3F62_42A0_9250_C714D9BF7285__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// MyTreeView.h : header file
//
/////////////////////////////////////////////////////////////////////////////
// MyTreeView view
class MyTreeView : public CTreeView
{
protected:
MyTreeView(); // protected constructor used by dynamic creation
DECLARE_DYNCREATE(MyTreeView)
// Attributes
public:
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(MyTreeView)
protected:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
//}}AFX_VIRTUAL
// Implementation
protected:
virtual ~MyTreeView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
// Generated message map functions
protected:
//{{AFX_MSG(MyTreeView)
// NOTE - the ClassWizard will add and remove member functions here.
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_MYTREEVIEW_H__10D3CC4C_3F62_42A0_9250_C714D9BF7285__INCLUDED_)
怎么回事?