Console.SetBufferSize Method (Int32, Int32)
Sets the height and width of the screen buffer area to the specified values.
Assembly: mscorlib (in mscorlib.dll)
The user does not have permission to perform this action.
An I/O error occurred.
The following example demonstrates the WindowLeft, WindowTop, WindowWidth, WindowHeight, BufferWidth, BufferHeight, and CursorVisible properties; and the SetWindowPosition, , and ReadKey methods. The example draws a grid pattern in the screen buffer based on the screen buffer width. Then the example moves the console window in response to which of the UP ARROW, DOWN ARROW, LEFT ARROW, or RIGHT ARROW console keys is pressed. The grid pattern helps you see the movement of the console window relative to the screen buffer.
Available since 2.0