anyone have any clever solutions for capturing a key when the alt key is pressed? Looking to grab up/down arrow when the alt key is pressed, but the keydown event does not fire.
- You are here:
- Home
- Q&A
- Q&A
- PowerBuilder
- keydown event doesn't trigger when alt key pressed
- mike S
- PowerBuilder
- Monday, 22 May 2023 13:44 PM UTC
Accepted Answer
- Monday, 22 May 2023 15:40 PM UTC
- PowerBuilder
- # Permalink
Hi Mike...haven't tried this so I can't provide any input on whether it would work for your use case but take a look at Andrew's reply to this posting: https://community.appeon.com/index.php/qna/q-a/how-can-i-catch-tab-key. The OP's question was around the tab key but the solution Andrew provided suggests that it would work for the Alt key as well.
HTH...regards,
Mark
Comment
- mike S
- Monday, 22 May 2023 15:52 PM UTC
thanks, yes that does look like what would have to be done. and it has the code for handling the alt key press
-
Helpful Loading... Helpful 0
There are no comments made yet.
- Monday, 22 May 2023 14:04 PM UTC
- PowerBuilder
- # 1
datawindow
Comment
- Chris Pollach @Appeon
- Monday, 22 May 2023 14:19 PM UTC
Are you assuming that the DC will always have focus when you're trying to capture the keystrokes!
-
Helpful Loading... Helpful 0
- mike S
- Monday, 22 May 2023 15:05 PM UTC
yes. works fine when you press the up/arrow or down arrow key. press alt key at the same time and it does not fire.
it isn't really a PB bug, but a 'feature' in windows. Seems to be some weird work arounds available in c# apps. I need to know if the alt key is pressed with those in order to make the UI work the same in my custom dddw's as it does in 'real' dddws.
it isn't really a PB bug, but a 'feature' in windows. Seems to be some weird work arounds available in c# apps. I need to know if the alt key is pressed with those in order to make the UI work the same in my custom dddw's as it does in 'real' dddws.
-
Helpful Loading... Helpful 0
There are no comments made yet.
- Monday, 22 May 2023 13:49 PM UTC
- PowerBuilder
- # 2
Hi Mike;
On what object class are you looking to capture this activity on?
Regards... Chris
Comment
There are no comments made yet.
- Page :
- 1
There are no replies made for this question yet.
However, you are not allowed to reply to this question.
However, you are not allowed to reply to this question.
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here. Register Here »