Hi,
how can I place a WinForm (C#) at the bottom-right of the screen when it pop-up?
thanks
Lennie
Hi,
how can I place a WinForm (C#) at the bottom-right of the screen when it pop-up?
thanks
Lennie
In you form constructor put the following code:
StartPosition = FormStartPosition.Manual;
This will set the start position of the form to whatever you set as the value for the form's location (you can set this in the form designer).
try something on the lines of
Rectangle workingArea = Screen.GetWorkingArea(this);
this.Location = new Point(workingArea.Right - Size.Width,
workingArea.Bottom - Size.Height);
Hope it works well for you.
Form2 a = new Form2();
a.StartPosition = FormStartPosition.Manual;
a.Location = new Point(Screen.PrimaryScreen.WorkingArea.Width - a.Width,
Screen.PrimaryScreen.WorkingArea.Height - a.Height);