Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynamically changing views in Doc/View architecture app

Status
Not open for further replies.

IoMatua

Programmer
Mar 27, 2003
17
NZ
Hi.

I was wanting to know if this was possible. Here's a breakdown of the situation.

My application consists of a number of sections. Within each section, are a number of components. Each component provides some form of interaction with the user.

At the moment, I've created and SDI application, created the CTreeView on the left side of the main frame which looks like this:

[tt]+-Section 1[/tt]
[tt]| |-Component 1[/tt]
[tt]| |-Component 2[/tt]
[tt]| |-Component 3[/tt]
[tt]+-Section 2[/tt]
[tt]| |-Component 1[/tt]

etc.

The right side of the main frame is a CListView. I've set it up so that when you click on a parent item in the CTreeView (the sections), it displays its child items in the list view (the components).

It might help to think of it like the Computer Mangament Console in Windows NT.

Now, I want to be able to change the view on the right side of the frame depending on what component is selected (either selecting from the CTreeView or CListView). For instance, some components retrieve records from a database, so I might need to chage the CListView into a CRecordView, other components use dialog controls, so I might need to use a CFormView.

Hopefully my explanation of the problem was clear enough. I'd greatly appreciate any advice, even if it means starting this project over again.

Thanks.
 
>> I was wanting to know if this was possible.

Sure it is. This has been previously discussed in this thread: thread116-513254

-pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top