 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Brian Guest
|
Posted: Sun Feb 15, 2004 11:22 pm Post subject: Stopping shift state from affecting sendkeys emulation |
|
|
Hello,
I'm trying to perform a generic "sendkeys" type of function. I've
searched google and found quite a few nice code examples that work well
for basic injecting of keystrokes into the keyboard
(http://bdn.borland.com/article/0,1410,16500,00.html and
[url]http://homepages.borland.com/efg2lab/Library/UseNet/1999/0311c.txt)[/url].
The problem I'm having is that if I am holding down a shift key, those
are also getting processed.
How can I prevent the current shift state of the keyboard from affecting
those injected keys?
Example:
Sendkeys('test'); // lowercase
will properly send 'test'. If I call that function while I'm holding
down the Shift key, it will result in:
'TEST' // uppercase (shifted)
It's also affecting if I'm holding down Alt, Ctrl, and/or Win.
Does anyone have ideas about this?
Thanks,
Brian
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|