Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/256.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# Can';不要从窗体底部移除填充物_C#_.net_Windows_Winforms_Padding - Fatal编程技术网

C# Can';不要从窗体底部移除填充物

C# Can';不要从窗体底部移除填充物,c#,.net,windows,winforms,padding,C#,.net,Windows,Winforms,Padding,有人能告诉我如何从没有填充的表单中删除底部填充吗 表单填充属性设置为: this.Padding = new System.Windows.Forms.Padding(0, 0, 0, 0); FormBorderStyle=sizable 但是表单有一个底部填充 我可以做一个新的,但我更喜欢理解这种形式的行为 和代码FormMainDesigner.cs: // FormMain // this.AutoScaleDimensions = new System.Drawing.Si

有人能告诉我如何从没有填充的表单中删除底部填充吗

表单填充属性设置为:

this.Padding = new System.Windows.Forms.Padding(0, 0, 0, 0);
FormBorderStyle=sizable
但是表单有一个底部填充

我可以做一个新的,但我更喜欢理解这种形式的行为

和代码FormMainDesigner.cs:

// FormMain
 // 
 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
 this.AutoSize = true;
 this.AutoValidate = System.Windows.Forms.AutoValidate.EnablePreventFocusChange;
 this.BackColor = System.Drawing.SystemColors.Control;
 this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
 this.CausesValidation = false;
 this.ClientSize = new System.Drawing.Size(1278, 758);
 this.ControlBox = false;
 this.Controls.Add(this.toolStrip1);
 this.Controls.Add(this.menuStrip1);
 this.Controls.Add(this.labelEmail);
 this.Controls.Add(this.statusStrip1);
 this.Controls.Add(this.radDock1);
 this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
 this.ForeColor = System.Drawing.SystemColors.ControlText;
 this.HelpButton = true;
 this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
 this.IsMdiContainer = true;
 this.MainMenuStrip = this.menuStrip1;
 this.Name = "FormMain";
 this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
 this.Text = "Sistema de Monitorização Energética";
 this.WindowState = System.Windows.Forms.FormWindowState.Maximized;
 this.Load += new System.EventHandler(this.FormMain_Load);
 ((System.ComponentModel.ISupportInitialize)(this.citiesBindingSource)).EndInit();
 ((System.ComponentModel.ISupportInitialize)(this.dataSetGeografia)).EndInit();
 this.menuStrip1.ResumeLayout(false);
 this.menuStrip1.PerformLayout();
 this.statusStrip1.ResumeLayout(false);
 this.statusStrip1.PerformLayout();
 this.contextMenuStripRoot.ResumeLayout(false);
 this.contextMenuStripTensionTypes.ResumeLayout(false);
 this.contextMenuStripCUnit.ResumeLayout(false);
 this.toolStrip1.ResumeLayout(false);
 this.toolStrip1.PerformLayout();
 ((System.ComponentModel.ISupportInitialize)(this.radDock1)).EndInit();
 this.radDock1.ResumeLayout(false);
 ((System.ComponentModel.ISupportInitialize)(this.toolTabStrip1)).EndInit();
 this.toolTabStrip1.ResumeLayout(false);
 ((System.ComponentModel.ISupportInitialize)(this.documentContainer1)).EndInit();
 ((System.ComponentModel.ISupportInitialize)(this.toolTabStrip2)).EndInit();
 this.toolTabStrip2.ResumeLayout(false);
 this.ResumeLayout(false);
 this.PerformLayout();

我认为这两条线之间存在冲突: 除去任何一个

this.AutoSize = true;


根据MSDN的说法,AutoSize是为了保证所有控件都能在不滚动的情况下显示在页面上。以后再把形状弄大可能没问题。。因此,状态栏前面有一个额外的空间,它应该是固定在底部的。

问题解决了。这是表格底部一个看不见的标签。只需删除标签。 下图显示了标签。
谢谢您的帮助。

请标记为
.net
或您正在使用的任何东西,然后发布代码。否则,没有人能“理解这种形式的行为”。欢迎来到Stack Overflow,谢谢Smandoli。可能是继承问题,但我找不到原因…底部的StatusStrip不是吗?不,不是StatusStrip。我将发布一个指向带有statusStrip的新screeshot的链接。为什么statusStrip在第一个图像中不可见?您有IsMdiContainer=true,但看起来没有空间容纳客户机表单。还不清楚白色边框是什么。
this.ClientSize = new System.Drawing.Size(1278, 758);