Horizontal scrollbar on tabPage2011-09-09 c# winforms scrollbar tabpage
Working in Design mode on Visual Studio 2010...
I am trying to get an horizontal scrollbar on a tabPage. From what I understood by reading here and there, setting the
AutoScroll property of the tabPage to
True should be enough to get scrollbars.
When I place a element on my tabPage that exceeds the bottom limit of the tabPage, I get an vertical scrollbar. But when I make an element exceed the right limit of the tabPage, no horizontal scrollbar appears.
What am I doing wrong?
Definitely doing something wrong there. I have just create a tabcontrol, set "AutoScroll" to true, selected the tab page element and added a new panel control (for testing). When I resize the control both the vertical and horizontal scroll bars are shown.
Are you sure you do not have any nested control elements? Perhaps the control that you think is outside the tab area is within a control than does not exceed the tab page bounds? In which case the scroll would not show
Found the problem: the control I was placing on my tabPage had the
Anchor property set to Top, Left, Right. It cannot work if there is Right.
Horizontal scrollbar problem can be caused Also if Dock = Fill . It should be Dock = None with Anchor= Right or Anchor= Left but not both.
- Disable horizontal AutScroll in Winforms, not just scrollbar
- Vertical & Horizontal scrollbars in a panel
- Horizontal Scrollbar Generated on Vertical scrollbar Overflow
- C# : How to add both scrollbars in a PictureBox contained in a SplitContainer Panel
- Set AutoScrollPosition of horizontal scrollbar on tabpage
- Windows Forms ListView missing horizontal scrollbar
- Horizontal ScrollBar in WinForms DataGridView
- Dynamic panel element adding and scrollbars
- Tabpage Resizing