S
schnandr
Hi I am trying to open a Form when the user hits the Enter key in a
list view.
private void listView_KeyUp(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
{
OnEnterKey();
}
}
I registered a KeyUp handler. When I open the Form and I press the
Enter key in the dialog the dialog closes and the KeyUp event will be
fired again from the list view and the dialog will open again. Why
will this event will be fired when I press Enter in the dialog?
Thanks for every hint.
list view.
private void listView_KeyUp(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
{
OnEnterKey();
}
}
I registered a KeyUp handler. When I open the Form and I press the
Enter key in the dialog the dialog closes and the KeyUp event will be
fired again from the list view and the dialog will open again. Why
will this event will be fired when I press Enter in the dialog?
Thanks for every hint.