C#: Enter key login in Winform form

Foreword:

When logging in to the form, press Enter to log in directly, which is more convenient and convenient.

solution:

Find AcceptButton in the form properties, and add the name of the button that is clicked by pressing the Enter key.

AcceptButton:

The "Receive" button of the form, if this button is set, every time the user presses the "Enter" key, it is equivalent to "click" to change the button.

Guess you like

Origin blog.csdn.net/weixin_44690047/article/details/112857215