Sign in to follow this  
Followers 0
ArthurK

[SOS] How to take over the system Hotkey?

5 posts in this topic

#1 ·  Posted (edited)

In AHK ,we can set any hotkey wich is taken by windows system.

so,how can we do the same thing in au3 scripts? Like win+1 ,in windows7 it's taken. Hotkeyset() is not perfect.

Forget my poor english.. :huh2:

Edited by ArthurK

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Hello ArthurK,

Welcome to AutoIt!

There are some key combinations you cannot set with HotKeySet() as per the Helpfile, there is a list of those keys that cannot be setup due to the operating system already utilizes them. I personally don't see why you would want to use key combinations that are already utilized by your system. I see many problems that could arise from a given instance, especially if your giving the script to other users.

I would reccommend setting up a different key combination. The only alternative would be using _IsPressed() to watch for the keys to be pressed.

Realm

Edit: Typos

Edited by Realm

My Contributions: Unix Timestamp: Calculate Unix time, or seconds since Epoch, accounting for your local timezone and daylight savings time. RegEdit Jumper: A Small & Simple interface based on Yashied's Reg Jumper Function, for searching Hives in your registry.  

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Thank you , Realm!

My scripts just for me ,but some system hotkey combinations are not useful. So , i think if i could make it useful will be very cool~

Just now ,I found two functions maybe make it work: _WinAPI_SetWindowsHookEx _WinAPI_RegisterHotKey . But the helpfile is so hard to read for me...

And i found a UDF Hotkey.au3 , but it's not working.If the problem is the different AU versions?

Thanks again, and forget my poor english , again~ :huh2:

Edited by ArthurK

Share this post


Link to post
Share on other sites

If you are running W7 you will find there are even more HotKeys reserved and Win + numeric will usually fail unless it is Win + numpad numeric.


George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0