Click here to Skip to main content
12,751,232 members (37,456 online)
Click here to Skip to main content
Add your own
alternative version


22 bookmarked
Posted 1 Jan 2010

Auto Hide Panel

, 5 Jan 2010 Apache
Rate this:
Please Sign up or sign in to vote.
How to implement an Adapter class to make panels of split container become auto hidden


If you want to have a useful and simple article for creating an Adapter class to make panels of SplitContainer become auto hidden, you have came to the right place. ;-)


There are a lot of samples on the internet that tell you how to create a class for this or modify some panels for this. But I saw that some of them are not perfect and clear! So I decided to implement a class (component) with the name of AutoHidePanel for this purpose.

Using the Library

Using this library is too simple and clear! Suppose that you put some SplitContainer in your form, then you drag and drop my AutoHidePanel component from the toolbox in the same form. Then all you need to do is set the MySplitterPanel property of my component (AutoHidePanel) to one of the panels of SplitContainer (Panel 1 or Panel 2).

  • In my library, there aren't any differences between choosing panel1 and panel2 in Microsoft SplitContainer.
  • If you change the RightToLeft property of form to Yes or No, everything works fine and properly.

Suppose that you select the panel1 of SplitContainer in my component. When you run the form (as you can see in the first picture) and your mouse pointer is over the panel1, you can see the panel1 in normal width. but when you move your mouse pointer over the panel2 (as you can see in the second picture) the panel1 will be hidden automatically.


This article, along with any associated source code and files, is licensed under The Apache License, Version 2.0


About the Author

Dariush Tasdighi
Web Developer Sematec Ins.
Iran (Islamic Republic of) Iran (Islamic Republic of)
My experiences are:

HTML 5.0, CSS 3.0
JQuery, Angular JS, Bootstrap

MVC 5.0, WEB API, c#

My Site URLs:

My Yahoo Group URL:

Mobile: 0098-912-108-7461
Address: Tehran, Tehran, Iran

You may also be interested in...

Comments and Discussions

General... Pin
hosseinghazanfary6-Dec-12 2:58
memberhosseinghazanfary6-Dec-12 2:58 
GeneralMy vote of 1 Pin
FernandoUY25-Jan-12 3:24
memberFernandoUY25-Jan-12 3:24 
GeneralMy vote of 4 Pin
Ankit Luthra28-Aug-10 3:16
memberAnkit Luthra28-Aug-10 3:16 
GeneralWonderfull Article Pin
NaDeRSetarei30-Jan-10 1:56
memberNaDeRSetarei30-Jan-10 1:56 
GeneralRe: Wonderfull Article Pin
Greizzerland30-Jan-10 5:44
memberGreizzerland30-Jan-10 5:44 
GeneralMy vote of 1 Pin
Kebrite11-Jan-10 18:18
memberKebrite11-Jan-10 18:18 
GeneralUnmeaning Vote Pin
NaDeRSetarei30-Jan-10 2:25
memberNaDeRSetarei30-Jan-10 2:25 
Generalcode Pin
konikula6-Jan-10 21:00
memberkonikula6-Jan-10 21:00 
GeneralMy vote of 1 Pin
JPaula6-Jan-10 0:11
memberJPaula6-Jan-10 0:11 
GeneralUnmeaning Vote Pin
NaDeRSetarei30-Jan-10 2:24
memberNaDeRSetarei30-Jan-10 2:24 
GeneralMy vote of 1 Pin
PSU Steve5-Jan-10 5:07
memberPSU Steve5-Jan-10 5:07 
GeneralRe: My vote of 1 Pin
Dariush Tasdighi5-Jan-10 8:54
memberDariush Tasdighi5-Jan-10 8:54 
GeneralRe: My vote of 1 Pin
Greizzerland15-Jan-10 7:27
memberGreizzerland15-Jan-10 7:27 
GeneralSecurity Update Pin
NaDeRSetarei30-Jan-10 2:54
memberNaDeRSetarei30-Jan-10 2:54 
GeneralRe: Security Update Pin
Greizzerland30-Jan-10 5:42
memberGreizzerland30-Jan-10 5:42 
GeneralMy vote of one: There is no article here Pin
ZTransform3-Jan-10 23:10
memberZTransform3-Jan-10 23:10 
GeneralRe: My vote of one: There is no article here Pin
Dariush Tasdighi4-Jan-10 9:04
memberDariush Tasdighi4-Jan-10 9:04 
RantRe: My vote of one: There is no article here Pin
Tom Spink5-Jan-10 14:11
memberTom Spink5-Jan-10 14:11 
GeneralComplaisance Package SP2 Pin
NaDeRSetarei30-Jan-10 2:42
memberNaDeRSetarei30-Jan-10 2:42 
GeneralMy vote of 1 Pin
ZTransform3-Jan-10 23:09
memberZTransform3-Jan-10 23:09 
Generalblind Member Pin
NaDeRSetarei30-Jan-10 2:26
memberNaDeRSetarei30-Jan-10 2:26 
GeneralMy vote of 1 Pin
Melionu3-Jan-10 12:09
memberMelionu3-Jan-10 12:09 
GeneralRe: My vote of 1 Pin
Dariush Tasdighi4-Jan-10 9:04
memberDariush Tasdighi4-Jan-10 9:04 
Generalcompassionate Member Pin
NaDeRSetarei30-Jan-10 2:31
memberNaDeRSetarei30-Jan-10 2:31 
GeneralMore info please Pin
spoodygoon2-Jan-10 8:11
memberspoodygoon2-Jan-10 8:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.170215.1 | Last Updated 5 Jan 2010
Article Copyright 2010 by Dariush Tasdighi
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid