Take the 2-minute tour ×

I have two displays (two monitors) connected to my machine, and I noticed a strange thing happening today. I had an Explorer window open with my compiled exe on my primary display, and when I double-clicked it, it opened in the primary display (left monitor). However if I pressed enter to launch the executable, it started in the secondary display (right monitor). The window state of the initial form is maximized. Is there a way to tell C# to open the initial form in the primary display?

share|improve this question
Thanks for the answers. Does anybody know what causes pressing enter vs double-clicking to result in diff behavior? –  JeffE Jan 10 '11 at 22:09

2 Answers 2

up vote 4 down vote accepted

This should do the trick:

static void Main()

    Form1 f = new Form1();
    f.StartPosition = FormStartPosition.Manual;
    f.Location = Screen.PrimaryScreen.Bounds.Location;

share|improve this answer

Take a look at this: Show form on primary or secondary screen

share|improve this answer

Your Answer


