C# WinForms Development
Posted on 2004-10-08
My question is best given by giving an example. Lets say I developed a form called Form1 which has 2 panes called LeftPane and RightPane. Contained on LeftPane are 2 labels, named Label1,Label2. If I click on Label1, I want to change the contents on RightPane. If I click on Label2 I also want to change the contents on RightPane.
This is kind of like using MS outlook where you click on inbox and the right pane shows your email. If you click on your address book the right pane shows your contacts.
I just want to be sure that I do this correctly. I had thought that I could make 2 more panes, contained inside of RightPane and when someone clicks on Label1, or Label2, I would just make the panes visiibility true or false. But I am wondering if this is a good idea as I will be initially loading all the panes. (I feel that this is probably the hack way around this.) So if anyone knows how to do this properly I would great appreciate the info.