| | |
Panel Mutiview? - Best Practice!!
Please support our C# advertiser: Intel Parallel Studio Home
Thread Solved |
•
•
Join Date: Sep 2009
Posts: 15
Reputation:
Solved Threads: 0
Hello All:
In asp.net there is a Multiview control which allows me to switch between panels programatically, so different sets of controls can selectively be displayed in the same area on screen.
I understand there is no such control in winForms but is there a best practice or technique for acheiving a similar operation?
Many thanks
Tino
In asp.net there is a Multiview control which allows me to switch between panels programatically, so different sets of controls can selectively be displayed in the same area on screen.
I understand there is no such control in winForms but is there a best practice or technique for acheiving a similar operation?
Many thanks
Tino
Depending on how you want them to appear visually, i usually use a TabControl if i want different sets of controls that the user can switch between.
If i want to change them in code in response to input then i normally design each of the panels, then place them one on top of the other and set all of them to .visible=false; .enabled = false; except for the one i want to be visible currently.
Not sure this is the 'best practice' but its always worked for me :p
If i want to change them in code in response to input then i normally design each of the panels, then place them one on top of the other and set all of them to .visible=false; .enabled = false; except for the one i want to be visible currently.
Not sure this is the 'best practice' but its always worked for me :p
Please don't take for granted the work that solvers do for you. Take the time to fully understand the code they give you so that you might adapt it to future problems.
"Learning is more than absorbing facts, it is acquiring understanding.” - William Arthur Ward
"Learning is more than absorbing facts, it is acquiring understanding.” - William Arthur Ward
•
•
Join Date: Sep 2009
Posts: 15
Reputation:
Solved Threads: 0
Thanks again Ryshad
Thats how I was going to do it (layerd panels) but wasnt sure if there was a better way.
Also looks like a bit of a mess on screen in VS, not easy to make alterations unless there is a way of disabling a panel on screen in VS too? Dont think so tho :-(
Many thanks for the help
Tino
Thats how I was going to do it (layerd panels) but wasnt sure if there was a better way.
Also looks like a bit of a mess on screen in VS, not easy to make alterations unless there is a way of disabling a panel on screen in VS too? Dont think so tho :-(
Many thanks for the help
Tino
I agree, designing them this way is a nightmare.
One option ive found is to lay them out side by side when im designing then set their location properties to all be the same when im done..either manually in the designer (edit the property rather than dragging them as you will probably end up with panels in panels if you drag them) or in the form load set their locations.
There may well be a better method, if there is i'd be keen to know it too :p I've always leaned more toward the TabControl since its neat and easy to use :p
One option ive found is to lay them out side by side when im designing then set their location properties to all be the same when im done..either manually in the designer (edit the property rather than dragging them as you will probably end up with panels in panels if you drag them) or in the form load set their locations.
There may well be a better method, if there is i'd be keen to know it too :p I've always leaned more toward the TabControl since its neat and easy to use :p
Please don't take for granted the work that solvers do for you. Take the time to fully understand the code they give you so that you might adapt it to future problems.
"Learning is more than absorbing facts, it is acquiring understanding.” - William Arthur Ward
"Learning is more than absorbing facts, it is acquiring understanding.” - William Arthur Ward
•
•
Join Date: Sep 2009
Posts: 15
Reputation:
Solved Threads: 0
•
•
•
•
One option ive found is to lay them out side by side when im designing then set their location properties to all be the same when im done..either manually in the designer (edit the property rather than dragging them as you will probably end up with panels in panels if you drag them) or in the form load set their locations.
![]() |
Similar Threads
- Windows ME no icons in Control Panel (Windows 95 / 98 / Me)
- Text breakage when panel is resized (Java)
- Help! Can't browse, use control panel or Explorer (Viruses, Spyware and other Nasties)
- Intel mainboard D845HV, front panel configuration (Motherboards, CPUs and RAM)
- Drawing A Table On A Container(Panel) (Java)
- ActionListeners on the components of a panel (Java)
- Problems in Win98SE with Desktop Shortcuts and The Control Panel (Windows 95 / 98 / Me)
Other Threads in the C# Forum
- Previous Thread: Visual C#: Inserting an Access Database Record
- Next Thread: DatagridView Help
| Thread Tools | Search this Thread |
.net 2007 access algorithm appportability array barchart bitmap box broadcast buttons c# camera check checkbox client combobox control conversion cs4 csharp custom database datagrid datagridview dataset date datetime degrees development draganddrop drawing encryption enum event eventcloseformc# excel file form format forms function gdi+ handler httpwebrequest image index input install java keypress label list listbox listener listview load mandelbrot math mouseclick mysql operator path photoshop picturebox pixelinversion post programming radians regex remote remoting richtextbox search security server sleep socket sql statistics stream string table text textbox thread time timer update usercontrol validation view visual visualstudio webbrowser windows winforms wordautomation wpf xml





