Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6974999
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T17:18:41+00:00 2026-05-27T17:18:41+00:00

I am experiencing a very strange issue with my Windows Forms form. As stated

  • 0

I am experiencing a very strange issue with my Windows Forms form. As stated in the title, the KeyUp event is not firing in the application at all until I alt+tab away from the window, then back. Doesn’t matter where I click in the application before switching away; nothing happens.

Also if I alt-tab away from the application, but click on the app’s task bar to switch back, then I still don’t get KeyUp events. Clicking away, then alt-tabbing back, makes the KeyUp event function properly again.

Seems I only get KeyUp events if I Alt-Tab TO the application – but not in any other case.

The KeyPreview property is true. I’m not doing any other key processing in the application anywhere – just in the KeyUp event.

I really need this application to be able to respond to KeyUp events, especially just after startup – I don’t want to instruct my users to alt-tab away then back just to have keyboard input function properly. Has anyone seen this issue and found a workaround?


Update: I’ve tinkered around with this a bit more, and I found a workaround – but it’s definitely a kludge and I don’t like it. In the OnShown override for the form, I added a call to this.Focus();. I also added an event handler for this.LostFocus that also calls this.Focus();. This is the only form in this application, so none of that is a problem – I just wish I understood why this is happening. =( Ah well.

I added this as an update instead of an answer because, well, this isn’t an answer. Bleh.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T17:18:41+00:00Added an answer on May 27, 2026 at 5:18 pm

    I ended up giving up on using form events – I’m now registering a global Windows hotkey for the key sequence I want to trap, and that’s working just fine. It doesn’t matter in my case that the hotkey is global, as my application is designed to be the only one in use on this system.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am experiencing a very strange issue. I have developped an application locally and
Hey guys, I'm currently experiencing a very strange crash in Windows 7 in a
I'm experiencing a very strange issue: I use the NUnit framework for testing in
I am experiencing a very strange issue with custom conflict handling using the Sync
I'm experiencing a very strange issue where I cannot see a Custom WPF control
I am experiencing some very strange mouse-event behaviour when working with Silverlights DataGrid: What
I'm experiencing what I think is a very strange issue. First and foremost, my
I am using JDK 1.6.0.18 for my Swing application. I am experiencing very different
I am experiencing a very frustrating issue when trying to insert a new record
I'm experiencing a strange PNG issue in my as3 flash project. I am loading

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.