🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #13908

Re: Low level keyboard

#13908
From: Remy Lebeau (TeamB)
Date: Mon, 08 Sep 2003 08:29
37 lines
2541 bytes
"Boguslaw Fries" <B.Fries@luca-online.de> wrote in message
news:3f5c3437@newsgroups.borland.com...

> How to catch characters : !"�$%&/()=? - I obtain instead 124567890

Since you are using a low-level hook, you'll probably have to track SHIFT
keystrokes as well, and translate teh keys manually.  Otherwise, you could
use a separate WH_CALLWNDPROC and intercept WM_CHAR messages, which will
have already translated the strokes for you.

> How to react on keyboard key pressed fo longer time ( key
> multiply - how much characters was sended)

Again, something that a low-level hook is too low to handle.  If you
intercept a message hook to intercept WM_KEYDOWN, then you can grab the
repeat count from the lKeyData value.  Bits 0-15 of the lParam will contain
the number of times the keystroke has been repeated from being held down by
the user.

> How to catch VK_INSERT ( check is overwrite or insert state )

The insert state is application-specific, not global in scope.  When your
DLL is injected into a new process, you will probably need to call
GetKeyState() or GetAyncKeyState() insiode of your DllEntryPoint(), store
the result into a variable that is unique for that instance of the DLL, and
then whenever you detect a VK_INSERT for a given process, update the
variable for the DLL instance that belongs to that process.


Gambit


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.515 / Virus Database: 313 - Release Date: 9/1/03
Technical Details
Message-ID: <3f5c3daf$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-08!supernews.com!priapus.visi.com!news-out.visi.com!petbe.visi.com!skynet.be!skynet.be!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <3f5c3437@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 10cc67,2875b50002bdcb6d
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-09-08 01:39:16 PST
From: "Remy Lebeau \(TeamB\)" <gambit47@yahoo.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f5c3437@newsgroups.borland.com>
Subject: Re: Low level keyboard 
Date: Mon, 8 Sep 2003 01:29:04 -0700
Lines: 39
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 207.175.226.26
Message-ID: <3f5c3daf$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1063009711 207.175.226.26 (8 Sep 2003 01:28:31 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-08!supernews.com!priapus.visi.com!news-out.visi.com!petbe.visi.com!skynet.be!skynet.be!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail