当前位置:编程学习 > C#/ASP.NET >>

statusToolStripStatusLabel 位置问题

我原来设计的时候希望效果是这样的:
但是当我运行的时候,效果图又变成这样:
显示hello world的 statusToolStripStatusLabel 位置变到右边了。.

相关code 如下
statusStrip 部分:
this.statusStrip1.Dock = System.Windows.Forms.DockStyle.None;
            this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.runningToolStripProgressBar,
            this.toolStripSplitButton1,
            this.helloworldToolStripStatusLabel,
            this.dpartmentAToolStripStatusLabel,
            this.dpartmentBToolStripStatusLabel,
            this.dpartmentCToolStripStatusLabel,
            this.dpartmentDToolStripStatusLabel,});
            this.statusStrip1.Location = new System.Drawing.Point(0, 0);
            this.statusStrip1.Name = "statusStrip1";
            this.statusStrip1.Size = new System.Drawing.Size(939, 22);

helloworldToolStripStatusLabel部分:
this.helloworldToolStripStatusLabel.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.helloworldToolStripStatusLabel.Name = "statusToolStripStatusLabel";
            this.helloworldToolStripStatusLabel.Size = new System.Drawing.Size(311, 17);
            this.helloworldToolStripStatusLabel.Spring = true;
            this.helloworldToolStripStatusLabel.Text = "hello world";
            this.helloworldToolStripStatusLabel.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;

请教各位高手帮忙解决一下。
--------------------编程问答-------------------- 图怎么没显示出来呢?




--------------------编程问答-------------------- 原来设计的时候希望效果是这样的

后来运行的时候变成这样了

原来位于左侧的hello world的 statusToolStripStatusLabel 位置变到右边了
补充:.NET技术 ,  C#
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,