Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.

Cannot set shortcut to Ctrl-ENTER

mpovidlov's profile image mpovidlov posted 9 months ago in General Permalink

I noticed that in the recent versions of HeidiSQL a shortcut Ctrl-ENTER is not accepted in the Shortucts interface if I try to use it to remap my keys. Is there a reason behind the change? I used to Ctrl-ENTER for the query execution and in previous versions of Heidi it worked. Then I changed that to something else and could not restore it back anymore...

ansgar's profile image ansgar posted 9 months ago Permalink

I suppose you mean the hotkey editor input in the preferences doesn't accept it. This input was a component from SynEdit before v11.1, and now it's a standard THotKey from Delphi's VCL. I was not aware it accepts a different set of hotkeys, but probably there is a reason for this particular one.

ansgar's profile image ansgar posted 9 months ago Permalink

That must be some bug in the VCL. Manually, in the Delphi IDE, I can assign Ctrl-Enter without a problem:

Description

jwan's profile image jwan posted 6 months ago Permalink

Hi, I am facing similar issue. Previously I had been upgrading one version to another, but today, I wanted to install from scratch and noticed that I can not assign CTRL+ENTER as the RUN for SQL.

Whats funny is that the default is F9, but then when i change it to another key and try to set back to F9 it does not allow anymore, with an error that says "Keyboard shortcut [F9] already assigned to "Apply filter"

ansgar's profile image ansgar posted 6 months ago Permalink

@jwan, that error dialog is actually a prompt, not an error, as it contains a question after the text you pasted here. And it should allow you to overwrite the existing hotkey.

jwan's profile image jwan posted 6 months ago Permalink

yes sir, acknowledged that it is a question, but then it is contradictory... if the F9 was already assigned (as default) to APPLY FILTER, then how come as a default too, it is the shortcut for RUN (under SQL)?

Since "APPLY FILTER" is under DATA while "RUN" is under SQL - meaning independent from each other during actual usage of the shortcut key - then assigning (or reassigning) F9 shouldnt ask the user if want to "remove it there and assign to "here" instead. right?

Also, in relation to the original poster, the CTRL+ENTER can not be assign as a shortcut to any of the functions, can this be fix?

I also found 2 bugs (maybe not a bug on a programmer's point of view):

  1. when i change any settings and click the OK or the APPLY button, the changes are applied. Thus making either the OK or the APPLY button as redundant, as well as not choosing APPLY and yet changes being applied makes it misleading.

  2. when settings were changed and applied, then I go back to PREFERENCES and click RESTORE DEFAULTS, a popup prompt ask if want to reset all preferences to default value. I click OK, but then all settings are still not back to default. The APPLY button also is not enable. I click OK to close the PREFERENCE window, and then reopen the PREFERENCE window, settings are still not back to default. I have to close and reload the Heidisql app, go to PREFERENCE and thats the time the default settings are shown.

  3. Without changing any settings from the PREFERENCE window, I do an IMPORT SETTINGS (obviously importing previously exported settings that contains changes in the PREFERENCE window), then go to PREFERENCE, none of the imported settings took effect. But same as #2 above, I close and reload the app and go straight to PREFERENCES, then the imported settings are shown.

The above are no big deal, but for newbies, they might not expect to just close and reload to have the settings to show up properly.

PS: using v11.2.0.6213 (64bit)

JAB Creations's profile image JAB Creations posted 1 month ago Permalink

I downloaded MiTeC Windows Registry Recovery to open up the following file: C:\Windows.old\Users\John\NTUSER.DAT

On the left navigation panel I clicked on "Raw Data".

I then navigated to Root ⇨ Software ⇨ HeidiSQL.

There is a hexadecimal key named "Shortcut1_actExecuteQuery". I copied the value which is "0000400D".

Then, with HeidiSQL closed, I then opened the Windows Registry Editor (Start ⇨ Run ⇨ regedit).

I then navigated to "Computer\HKEY_CURRENT_USER\SOFTWARE\HeidiSQL".

I found the hexadecimal key named "Shortcut1_actExecuteQuery" (created only if you attempted to change the setting in the program, you may have to manually create it). I pasted the value "0000400D" and then confirmed it worked in HeidiSQL!


ansgar, if it's not too much trouble, what binary tool (or website even) can we use to generate the hexadecimal values manually? That might help alleviate pressure for everyone as a temporary stop-gap.

1 attachment(s):
  • heidisql_ctrl-enter
kthanid's profile image kthanid posted 1 month ago Permalink

Came here to report the same issue. It appears anytime "Enter" (or keypad "Enter") is used to assign a shortcut in the "Tools -> Preferences -> Shortcuts" UI, it clears the shortcut back to "None".

Thanks to @JAB Creations for the workaround above. In case anyone else is looking to apply this to a portable installation of HeidiSQL, simply add (or edit) the line below in the "portable_settings.txt" file in the program's root directory ("16397" being the decimal equivalent of "0000400D"):

Shortcut1_actExecuteCurrentQuery<|||>3<|||>16397

As mentioned above, if there was a way to easily derive/generate these key values outside of the HeidiSQL UI, that would help in working around this current limitation in the meantime.

Please login to leave a reply, or register at first.




Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.