Hi all,
I'm using luaMacros to create a secondary keyboard to make certain functions I perform much easier.
One such issue is in Microsoft SQL Server Management Studio. To switch between SQL windows, the key combination is an annoying "ctrl+F6"
If I use sendkeys('^{F6}') on "page up" this works for sending a single instance, and the application switches from window 1 to window 2. Pressing it again just switches back from window 2 to window 1 again. What I'm trying to do is enable holding down "page up" to cycle through the windows, which involves pressing and holding CTRL, then repeatedly pressing F6.
Anyone have any thoughts on how to achieve this? I'd even be happy to use a double-combination on the macro keyboard.
many thanks,
Dave
send key combinations with persistence
Re: send key combinations with persistence
In other words you want to be able to send key down only (for Ctrl) - without key up (and vice versa)?
Petr Medek
LUAmacros author
LUAmacros author
Re: send key combinations with persistence
pretty much yes - in principle I think the sequence would be:
send key down (this state persists until otherwise)
followed by send key {F6} by each repetition from the user, fooling the system into thinking the ctrl key is held down whilst the F6 key is pressed repeatedly at the users instruction (i.e {F6 10} does not do what is needed as it just repeats it a specified number of times and not at the users control.)
I am quite happy to have a two part solution i.e. one key sets the ctrl key down event as on or off and another key does F6 as per the users keypress, making it an easily one handed solution for those having difficulty making this key-combination - not everyone has 10 fingers & thumbs of normal size.
send key down (this state persists until otherwise)
followed by send key {F6} by each repetition from the user, fooling the system into thinking the ctrl key is held down whilst the F6 key is pressed repeatedly at the users instruction (i.e {F6 10} does not do what is needed as it just repeats it a specified number of times and not at the users control.)
I am quite happy to have a two part solution i.e. one key sets the ctrl key down event as on or off and another key does F6 as per the users keypress, making it an easily one handed solution for those having difficulty making this key-combination - not everyone has 10 fingers & thumbs of normal size.
Re: send key combinations with persistence
Ok, I'll see what can be done when I'll be rewriting unit for key sequence.
However it won't be soon...
However it won't be soon...
Petr Medek
LUAmacros author
LUAmacros author
Re: send key combinations with persistence
Hi there,
In the meantime one can eventualy call an AutoIT script and use its somewhat extended possibilities ...
Greatings
Thomas
ps:
on the other side, luamacros has some internal functions send_key_down / up - that could be made available...
(I know, there is some code in luamacros that trys to deal with key-pressed while other keys should be sent -> see source uSendKeys.pas - but I haven't understood the mechano and problem till yet... )
In the meantime one can eventualy call an AutoIT script and use its somewhat extended possibilities ...
Greatings
Thomas
ps:
on the other side, luamacros has some internal functions send_key_down / up - that could be made available...
(I know, there is some code in luamacros that trys to deal with key-pressed while other keys should be sent -> see source uSendKeys.pas - but I haven't understood the mechano and problem till yet... )