Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Form::ProcessDialogKey Method (Keys)

 

Processes a dialog box key.

Namespace:   System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

protected:
[UIPermissionAttribute(SecurityAction::LinkDemand, Window = UIPermissionWindow::AllWindows)]
virtual bool ProcessDialogKey(
	Keys keyData
) override

Parameters

keyData
Type: System.Windows.Forms::Keys

One of the Keys values that represents the key to process.

Return Value

Type: System::Boolean

true if the keystroke was processed and consumed by the control; otherwise, false to allow further processing.

The ProcessDialogKey method overrides the base ContainerControl::ProcessDialogKey implementation to provide additional handling of the RETURN and ESCAPE keys in dialog boxes. The method performs no processing on keystrokes that include the ALT or CONTROL modifiers.

.NET Framework
Available since 1.1
Return to top
Show:
© 2017 Microsoft