public static void ShowConsole() { if (hasConsole) return; NativeMethods.AllocConsole(); hasConsole = true; }