Vertically aligning controls in a TableLayoutPanel

Flynn1179 picture Flynn1179 · Sep 9, 2010 · Viewed 22.6k times · Source

Is there any way to have textual content of controls on a TableLayoutPanel align themselves properly? I've got labels in column 0, and textboxes (or occasionally ComboBox or NumericUpDown controls) in column 1, but the text in the label is usually a pixel or two out (vertically) on most rows.

Answer

keegan picture keegan · May 24, 2012

Select all the controls in your table layout panel. In the properties tab ensure anchor set to 'left'. I think it defaults to 'top,left'.
Hope that sets things straight.