csavalas / HotkeyMapper

Hotkey Mapper for Lenovo Thinkpads
15 stars 0 forks source link

Support for changing calculator #3

Open Olli-M opened 2 months ago

Olli-M commented 2 months ago

I want to open a different calculator app from the calculator key (equals in the numpad area) The keycode is EX92 according to Procmon when following the #1 instructions. My laptop is a lenovo P53

csavalas commented 2 months ago

Hi Olli,

I don't have support for the calculator key built into the current version of the app. If you'd like to perform that customization in the meantime, try this out: Navigate to: Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Lenovo\ShortcutKey\AppLaunch\Ex_92 in regedit.exe and take screenshots of the contents for me to take a look.

Olli-M commented 2 months ago

Interestingly enough it seems to not be found at all, I did check and its the 64 bit regedit and searched for Ex_92 throughout the registry but it isn't there at all. Very strange. I added a picture from procmon, from regedit, as well as the exported file from procmon, just in case that will help.

I did check for Ex_92 in:

but it does not exist in any of them. The software folder (last) does not even have a folder for lenovo.

Without seing how the program works, I suspect its maybe trying to check if there are any defined registry settings for those keys and then depending on that either opening the preset calc.exe or not.

Procmon Shortcutkey Screenshot (3) SHTCKY.zip

csavalas commented 2 months ago

Hi Olli,

As a test, try importing this into your registry, and let me know if that calculator key now opens notepad.exe instead:

olli_notepad_test.zip

Olli-M commented 2 months ago

Hi, That changed nothing, still ran normally, but upon checking the values of Ex_13, and using similar values I got it to work. It should be this, except that the registry value has to be in the REG_EXPAND_SZ format.

[HKEY_LOCAL_MACHINE\SOFTWARE\Lenovo\ShortcutKey\AppLaunch\Ex_92]
"AppType"=dword:00000003

[HKEY_LOCAL_MACHINE\SOFTWARE\Lenovo\ShortcutKey\AppLaunch\Ex_92\UIAccess]
"File"="C:\Windows\System32\notepad.exe"
"Parameters"=""

It does not however work for a variety of other apps, I have tested:

I have attached a working log (Notepad) as well as a not working log (Word)

Logs.zip

p.s. I don't know if all windows languages need it, but the S in System32 needs to be capitalized, was doing a bit of debugging and it threw me for a loop for a bit. First I thought I needed to have it be: %SystemRoot%\System32\notepad.exe until I figured that out.