25 Apr
2008
25 Apr
'08
1:07 p.m.
Lei Zhang wrote:
On Thu, Apr 24, 2008 at 10:22 PM, Lei Zhang <thestig(a)google.com> wrote:
Hi,
This should be the last bit in getting control + enter working in multiline edit controls. I attempted to write a test for this using SendInput() or SetKeyState() + SendMessage(), but I couldn't get seem to simulate holding down the control key.
Should work. You can also look at keybd_event() how it does it. It's pretty much a wrapper around SendInput(). All you'll need is keybd_event(VK_CONTROL, 0, 0, 0); to press it. And keybd_event(VK_CONTROL, 0, KEYEVENTF_KEYUP, 0); to release it. Vitaliy.