Category : virtual-keyboard

I’m trying programmatically press a key in other app. Using functions of user32.dll (btw, does it make sense if the app is 64-bit application). I do smth like this: const uint KEYEVENTF_EXTENDEDKEY = 0x0001; const uint KEYEVENTF_KEYUP = 0x0002; private const int VK_F9 = 0x78; [DllImport("user32.dll", CharSet = CharSet.Auto)] public static extern IntPtr FindWindowEx( IntPtr ..

Read more

Is there an elegant way in C++ (Windows) to take string representation of a virtual key code (e.g. VK_NUMPAD0, VK_F6, VK_INSERT, VK_RSHIFT, etc.) and convert it to its corresponding hexadecimal value (e.g. 0x60, 0x75, 0x2D, 0xA1, etc.)? Currently, I know using a switch statement, if statement, map, etc. will work (and I am using this ..

Read more