title: Allowing function shortcut keys during message box popup
body: <p>When a user enters an incorrect value, a message box will show up and read "Entry not a match. Do you want to overwrite?". When this message box appears, I would like for the user to be able to hit the F1 key and have a separate page show when this shows up without them having to close the message box. Is this possible with the way I have my code or do I need to restructure this whole deal? </p>
  
  <pre><code>if (MessageBox.Show("Entry not a match. Do you want to overwrite?", "", MessageBoxButton.YesNo) == MessageBoxResult.Yes)
                  {   //below is the code I want to use as the shortcut for when the messae box appears if it is possible to do it this way
  
  if (e.Key == Key.F1)
          {
              viewEntry page = new viewEntry ();
              page.textBox.Text = textBox.Text;
              page.ShowDialog();
          }
                      if (MessageBox.Show("Confirm Overwrite", "", MessageBoxButton.YesNo) == MessageBoxResult.Yes)
                      {
                          //do something
  
                      }
                      tnImage.Text = "✓";
                      tnImage.FontSize = 22;
                      tnImage.Foreground = new SolidColorBrush(Colors.Green);
                      txtTN.BorderBrush = new SolidColorBrush(Colors.Green);
                      txtBN.Focus();
                  }
                  else
                  {
                      return;
                  }
  </code></pre>