I am creating a login form for a Windows Phone application, I want to trigger a login button event when I press the enter button, ending the form.
Requirement: . When you press the enter button from the last text field on the login page, you must trigger the login button event.
Sample Code I know how to move from one text box to another by pressing the enter button as shown below
private void passkeydown(object sender, KeyEventArgs e)
{
if (e.Key == Key.Enter)
{
nextfield .Focus();
}
}
But I do not know how to trigger a button click event here.
source
share