tags:

views:

54

answers:

1

Hello all

I want to start creating an application that has a menu on the left(some items in a tree) and I want to open different pages on the right on the form when I click these items. Could anybody guide me in doing this correctly pls? I dont want to have tons of data in memory and just display these pages one in top of another.

Thanks

+1  A: 

One approach is to have treeview docked on the left and a panel docked to fill. Then, on the SelectedNodeChanged event of the tree, you can load forms into the panel. Just be sure to clear out the old form every time you change nodes.

By pages, do you mean web pages? If so, take a look at the WebBrowser control.

matt eisenberg
I'm specially interested in this one: "Just be sure to clear out the old form every time you change nodes."
phm
panel1.controls.clear(), otherwise you'll end up with a stack of forms inside the panel
matt eisenberg
Clear() isn't good enough. You'll have to Dispose() too.
Hans Passant