![]() |
VOOZH | about |
Console.SetWindowSize(Int32, Int32) Method is used to change the height and width of the console window to the specified values.
Syntax: public static void SetWindowSize (int width, int height); Parameters: width: The width of the console window measured in columns. height: The height of the console window measured in rows.
Exceptions:
Example 1: Getting the current dimensions of the window.
Output: 👁 Image
Example 2: Setting the value of SetWindowSize
Output: 👁 Image
Note: See the Horizontal Scroll Bar at the bottom of the Window in both the images. Reference: