I tried this method: (but at startup it does not immediately appear in the center, but with a delay)
[DllImport("kernel32.dll", ExactSpelling = true)] public static extern IntPtr GetConsoleWindow(); [DllImport("user32.dll", EntryPoint = "SetWindowPos")] public static extern IntPtr SetWindowPos(IntPtr hWnd,int hWndInsertAfter, int x, int Y, int cx, int cy, int wFlags); public const int SWP_NOSIZE = 0x0001; public static IntPtr MyConsole = GetConsoleWindow(); public static void Inizialize() { var xpos = 450; var ypos = 350; SetWindowPos(MyConsole, 0, xpos, ypos, 0, 0, SWP_NOSIZE); } Is it possible to call the console in the central ( CenterScreen ) area immediately at startup, without delay?