如何将windows.form的开始位置设置为底部?

时间:2019-02-22 07:28:14

标签: c# visual-studio winforms

有什么方法可以使“ StartPosition”开始“底部”

Reference

enter image description here

1 个答案:

答案 0 :(得分:3)

使用位置属性。

this.Location = new Point((Screen.PrimaryScreen.WorkingArea.Width - this.Width) / 2,
                          (Screen.PrimaryScreen.WorkingArea.Height - this.Height));

public Form1()
{
    InitializeComponent();
    this.StartPosition = FormStartPosition.Manual;
    this.Location = ...;
}