From: rockdale on
Hi, all:

All my experience on MFC is dialog based application. And now I try to
learn the SDI and MDI based application. I create a sample SDI
application, but then I have no idea what is the next step I need to
do. Like if I want use can enter some data in a CEdit control, how
should I do that. Do I need to create a CDialog and then load it into
the main frame, how to load a CDialog/CView into a main frame, all the
examples on the internet are showing an empty childview, how can I
make the childview doing something?

Thanks in advance.
-Rockdale
From: Seetharam on
The view has an OnDraw() function that you can implement to be able to
something in your view..
Typically, the CDocument object will hold some data that the view
will paint.
There are tons of examples in codeguru, codeproject and MSDN.

-Seetharam
From: rockdale on
Thanks. I checked both site before post my question but find nothing.

I made a little progress, I have to add a FORMVIEW into my resource
file then work from there, correct?

Can somebody point me to the right direction or links?

Thanks a lot
-Rockdale

On Jan 18, 5:33 pm, Seetharam <smi...(a)gmail.com> wrote:
> The view has an OnDraw() function that you can implement to be able to
> something in your view..
> Typically, the  CDocument object  will hold some data that the view
> will paint.
> There are tons of examples in codeguru, codeproject and MSDN.
>
> -Seetharam

From: Hans-J. Ude on
The scribble sample is a good point to start:

http://msdn.microsoft.com/en-us/library/f35t8fts.aspx

From: Joseph M. Newcomer on
As pointed out, you want a CFormView. The problem is that generally an SDI app doesn't
really add much over a dialog-based app. MDI is the place to be. That way, you can have
a view which is a CFormView in which you enter data, another view where the OnDraw plots
the data, and you can consider things like doing 3-D where one view is from the top, one
from the front, one from the left, etc. I have found SDI to be approximately useless
nearly all the time, but MDI is extremely powerful, even if you never have more than one
document open (you can even limit it, although that doesn't always make sense). But those
multiple concurrent views are a lot of power. Similarly CSplitterWnd is a very powerful
model, where you can have multiple views with a single document.

As already observed, the Scribble tutorial is one of the really best ways to learn SDI and
MDI. I learned MFC in three days using the Scribble tutorial (then spent about two years
getting competent)
joe
On Mon, 18 Jan 2010 14:01:27 -0800 (PST), rockdale <rockdale.green(a)gmail.com> wrote:

>Hi, all:
>
>All my experience on MFC is dialog based application. And now I try to
>learn the SDI and MDI based application. I create a sample SDI
>application, but then I have no idea what is the next step I need to
>do. Like if I want use can enter some data in a CEdit control, how
>should I do that. Do I need to create a CDialog and then load it into
>the main frame, how to load a CDialog/CView into a main frame, all the
>examples on the internet are showing an empty childview, how can I
>make the childview doing something?
>
>Thanks in advance.
>-Rockdale
Joseph M. Newcomer [MVP]
email: newcomer(a)flounder.com
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm