Sertan Pekel
Sertan Pekel

Reputation: 611

TableLayoutPanel cell border style with columnspan

I have a tablelayoutpanel which I create programmatically. My problem is I have some textboxes which have columnspan value like that image:

I do not want to see cutted border lines as seen on second, third, fourth..rows. I tried that solution (Draw borders around some cells in a tablelayoutpanel) already but I do not know how to apply to my control, beacuse It draws very first cell border lines only.

Any Ideas?

Upvotes: 1

Views: 2398

Answers (1)

LarsTech
LarsTech

Reputation: 81620

Try placing your TextBox control inside a Panel with these settings:

panel1.Dock = DockStyle.Fill;
panel1.Margin = new Padding(0);

then just center your TextBox control inside of the panel.

Upvotes: 3

Related Questions