Login Page - Create Account

Support Board


Date/Time: Mon, 16 Sep 2024 19:12:29 +0000



Post From: Keyboard Shortcut: Ctrl + Number

[2022-12-24 03:28:56]
ondafringe - Posts: 276
According to Global Settings > Customize Keyboard Shortcuts:

Ctrl + NumPad Number is not being used by SC, and I am using the Number Pad.

And Shift + Any Number is not being used by SC, either.

So I tried:

if (sc.IsKeyPressed_Shift && pressedCharacter == 52) // ASCII Number 4
{
//some code
}

and I tried:

if (sc.IsKeyPressed_Control && sc.IsKeyPressed_Shift && pressedCharacter == 52) // ASCII Number 4

{
//some code
}

... and it still doesn't work.

In fact, even with NumLock on:

Shift + 2 and Ctrl + Shift + 2 maps to the down-cursor key

and:

Shift + 8 and Ctrl + Shift + 8 maps to the up-cursor key

...even though "Global Settings > Customize Keyboard Shortcuts" doesn't show those key combos are being used by SC. Why do that? Doesn't make sense to me, but I guess it really doesn't matter because nothing else works anyway.

And, again, I can check for the individual keys separately, and it works, but the key combos are DOA.

According to the following old support thread, there is a custom study called "Keyboard Receive Event Examples," but I can't locate that study. And the trader in that old support thread appears to have solved the problem. I think I am doing it the way that trader is doing it, so it's confusing as to why it still doesn't work for me.

Using Keyboard Shortcuts in ACSIL

With all the traders having problems getting this to work over the years, it seems like SC would have better documentation, along with examples, by now. Maybe they do and I just can't find what I'm looking for. Seriously, if SC can get key combinations to work, we should be able to get them to work, as well. So, IMO, it can't be the OS.

I'll keep using my work-around while I try to figure this out, but it's not an ideal solution.