Log in

View Full Version : how to use document-view in eVC


ajoshi123
09-11-2002, 06:09 AM
Hi !

I have a SDI (document-view) architecture in eVC. Now I want to associate multiple views with a single document.

Say, initially there is a login view. When the user clicks on the login button, the view changes to say the user's details.
I am using CFormView. To each subclass of the CFormView a dialog box is attahed.
The MFC provides a method AddView(CView *pView).
But the creation process of CFormViews has protected access.
How do I solve this problem. Please help !!!

/dev/niall
09-24-2002, 07:00 AM
Not sure if this helps, I never use Form views so I'm not familiar with the specific problem you seem to be having.

Check out the "stasplit" sample that came with your PPC 2002 SDK:

\Windows CE Tools\wce300\Pocket PC 2002\samples\mfc\stasplit

You'll see an example of attaching multiple views to a single document... just peek at mainfrm.cpp.