Console.ReadKey Method

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Obtains the next character or function key pressed by the user.

Namespace:   System
Assembly:  mscorlib (in mscorlib.dll)

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticReadKey()

Obtains the next character or function key pressed by the user. The pressed key is displayed in the console window.

System_CAPS_pubmethodSystem_CAPS_staticReadKey(Boolean)

Obtains the next character or function key pressed by the user. The pressed key is optionally displayed in the console window.

Return to top
Show: