Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

MyProgTreeView.h(8) error C2504: 'CTreeView' : base class undefined

124 views
Skip to first unread message

Hulemannen

unread,
Apr 3, 1996, 3:00:00 AM4/3/96
to
When I add a class derived from CTreeView with ClassWizard, Visual C++
4.0 throws this error message at me:

MyProgTreeView.h(8) error C2504: 'CTreeView' : base class undefined

the line look like this:

class CMyProgTreeView : public CTreeView

Someone please tell me what is going on!
--
,,,
(o o)
================================oOO==(_)==OOo===============================
Steinar Elgsaeter, Norway | Those who can -- do.
E-mail : el...@nobipol.unit.no | Those who cannot -- teach.
Also known as: | Those who cannot teach --
administrate.
"Elgen" and "Caveman" | .oooO Oooo. - H.L.Mencken's Law
================================( )==(
)================================
\ ( ) /
\_) (_/

Leen van Kampen

unread,
Apr 3, 1996, 3:00:00 AM4/3/96
to
Try:

#include "afxcview.h"

Steve Brailsford

unread,
Apr 3, 1996, 3:00:00 AM4/3/96
to el...@nobipol.unit.no
Hulemannen wrote:
>
> When I add a class derived from CTreeView with ClassWizard, Visual C++
> 4.0 throws this error message at me:
>
> MyProgTreeView.h(8) error C2504: 'CTreeView' : base class undefined
>
> the line look like this:
>
> class CMyProgTreeView : public CTreeView
>
> Someone please tell me what is going on!

You need to add this. I added it to stdafx.h

#include <afxcview.h> // MFC Common controls

--
Steve Brailsford Steve.Br...@smg.seagate.com
Seagate Software Orlando, FL

John E. Whitaker

unread,
Apr 3, 1996, 3:00:00 AM4/3/96
to
Hulemannen wrote:
>
> When I add a class derived from CTreeView with ClassWizard, Visual C++
> 4.0 throws this error message at me:
>
> MyProgTreeView.h(8) error C2504: 'CTreeView' : base class undefined
>
> the line look like this:
>
> class CMyProgTreeView : public CTreeView
>
> Someone please tell me what is going on!
> --
> ,,,

Try including <afxcmn.h> in your header.

John

David Connet

unread,
Apr 3, 1996, 3:00:00 AM4/3/96
to
In article <316286...@nobipol.unit.no>,

Hulemannen <el...@nobipol.unit.no> wrote:
>When I add a class derived from CTreeView with ClassWizard, Visual C++
>4.0 throws this error message at me:
>
>MyProgTreeView.h(8) error C2504: 'CTreeView' : base class undefined
>
>the line look like this:
>
>class CMyProgTreeView : public CTreeView
>
>Someone please tell me what is going on!

You need to include #include <afxcview.h> in stdafx.h. (It's noted in the
overview for CTreeView in the help file.)

--------------------
Dave Connet
Dave_...@corp.dialog.com

My opinions are my own. I think...

0 new messages