FlowLayoutPanel


The FlowLayoutPanel control displays the controls that it contains in rows or columns. For example, when laying out rows, it places controls next to each other horizontally in a row until it runs out of room, and then it starts a new row.

The FlowLayoutPanel is particularly useful for Toolboxes and in situations where the goal is to display as many of the contained controls as possible at one time, and the exact arrangement of the controls isn’t too important.

The control’s FlowDirection property determines the manner in which the control arranges its contained controls. This property can take the values LeftToRight, RightToLeft, TopDown, and BottomUp. Figure G-5 shows these different arrangements.

The control’s AutoScroll property determines whether the control automatically provides scroll bars if its contents won’t fit within the control all at once.

The Padding property determines how much space the control leaves between its edges and the controls it contains. Use the Margin properties of the contained controls to specify the spacing between the controls.

The TableLayoutPanel control also arranges contained controls, but in a grid. For information on that control, see the section “TableLayoutPanel” later in this appendix.

image from book
Figure G-5: The FlowLayoutPanel control can arrange its contents from left to right, right to left, top-down, or bottom-up.




Visual Basic 2005 with  .NET 3.0 Programmer's Reference
Visual Basic 2005 with .NET 3.0 Programmer's Reference
ISBN: 470137053
EAN: N/A
Year: 2007
Pages: 417

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net