How to: Span Rows and Columns in a TableLayoutPanel Control

Controls in a TableLayoutPanel control can span adjacent rows and columns.

NoteNote:

The dialog boxes and menu commands you see might differ from those described in Help depending on your active settings or edition. To change your settings, choose Import and Export Settings on the Tools menu. For more information, see Visual Studio Settings.

To span columns and rows

  1. Drag a TableLayoutPanel control from the Toolbox onto your form.

  2. Drag a Button control from the Toolbox into the upper-left cell of the TableLayoutPanel control.

  3. Set the Button control's ColumnSpan property to 2. Note that the Button control spans the first and second columns.

  4. Set the Button control's RowSpan property to 2. Note that the Button control spans the first and second rows.

  5. Set the Button control's ColumnSpan property to 1. Note that the Button control moves into the first column and spans the first and second rows.

http://msdn.microsoft.com/en-us/library/ms171687(v=VS.90).aspx

 

你可能感兴趣的:(合并单元格,职场,休闲)