C#中最简单的分隔线

其实就是将label的BorderStyle属性设置为Fixed3D,高度为2就OK了.

附代码:
===================================================================

this.label1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
this.label1.Location = new System.Drawing.Point(8, 120);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(344, 2);

你可能感兴趣的:(C#中最简单的分隔线)