TimRude Posted December 16, 2022 Share Posted December 16, 2022 In an AutoIt created GUI with pretty much any control on it, if an 'invalid' key is pressed (i.e. a key that doesn't go to anything), the Windows 'Default Beep' sound is played. I'd like to prevent that sound from occurring in the GUI of one of my AutoIt apps, without globally changing any of the user's sound settings. For example, if you run the GUICreate.au3 example script associated with the GUICreate() help topic and then begin typing the alphabet, it beeps on each keypress (unless you've disabled the Default Beep sound in your Windows settings). Is there an easy way to have it just ignore invalid or meaningless keypresses rather than screaming in pain about them? Interestingly enough, if you comment out the part of the GUICreate.au3 script that creates the button control, so that you have just a bare GUI window with no controls on it, then there are no beeps triggered by errant keypresses. But then adding just about any other control to the GUI where A B C aren't valid keypresses will bring back the beeps. Link to comment Share on other sites More sharing options...
argumentum Posted December 16, 2022 Share Posted December 16, 2022 AutoIt uses the win32 controls, so unless you "draw" your own, the windows canvas will do what the ... system will do. I don't think that you can avoid that Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting. Link to comment Share on other sites More sharing options...
TimRude Posted December 16, 2022 Author Share Posted December 16, 2022 Bummer. Oh well. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now