Changing Console Window's size throws ArgumentOutOfRangeException
问题 I am trying to set the size of the Console Window in a c# console application. I get an ArgumentOutOfRangeException with this message: The value must be less than the console's current maximum window size of 41 in that dimension. Note that this value depends on screen resolution and the console font. I am using this to set it: Console.WindowHeight = 480; How do you set the Console window's size properly? 回答1: From MSDN of Console.WindowHeight property: The height of the console window