From: dushkin on
Hi All,

I need your advice please:

I almost have no experience in doc\view applications.

I would like to build an explorer-like mfc application.
For that I used the app wizard. I created an SDI application (hope it
is the right choice), with a form view as the right view.

My difficulty is in knowing what to do when I select an item on the
tree control, the Left View.
There are multiple item types in my tree for which I want to display
their properties in the right view.
So I want to show different form views for each tree item type.

One solution, which I don't like, is to build one dialog and show
\hide controls.

But is there a way I can prepare a dialog for each item type and show
it according to the selection?

Thanks!
From: ScottMcP [MVP] on
On May 24, 2:32 am, dushkin <dush...(a)012.net.il> wrote:
> Hi All,
>
>  I need your advice please:
>
>  I almost have no experience in doc\view applications.
>
>  I would like to build an explorer-like mfc application.
>  For that I used the app wizard. I created an SDI application (hope it
> is the right choice), with a form view as the right view.
>
>  My difficulty is in knowing what to do when I select an item on the
> tree control, the Left View.
>  There are multiple item types in my tree for which I want to display
> their properties in the right view.
>  So I want to show different form views for each tree item type.
>
>  One solution, which I don't like, is to build one dialog and show
> \hide controls.
>
>  But is there a way I can prepare a dialog for each item type and show
> it according to the selection?
>
> Thanks!

Yes, you can switch the right view window to another CFormView derived
class. See the view switcher example SWSPLIT at
http://support.microsoft.com/kb/199515

From: Tom Serface on
You may also find these articles to be interesting:

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

http://www.functionx.com/visualc/applications/explorer.htm

If you need to actually show files from the OS these new controls may be
useful to you as well:

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

Tom

"dushkin" <dushkin(a)012.net.il> wrote in message
news:1d5a675c-31cb-4dd8-933e-ea9ae4f423d5(a)40g2000vbr.googlegroups.com...
> Hi All,
>
> I need your advice please:
>
> I almost have no experience in doc\view applications.
>
> I would like to build an explorer-like mfc application.
> For that I used the app wizard. I created an SDI application (hope it
> is the right choice), with a form view as the right view.
>
> My difficulty is in knowing what to do when I select an item on the
> tree control, the Left View.
> There are multiple item types in my tree for which I want to display
> their properties in the right view.
> So I want to show different form views for each tree item type.
>
> One solution, which I don't like, is to build one dialog and show
> \hide controls.
>
> But is there a way I can prepare a dialog for each item type and show
> it according to the selection?
>
> Thanks!