Click here to Skip to main content
15,890,438 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Help on Listbox Pin
Dave Kreskowiak1-Aug-05 7:46
mveDave Kreskowiak1-Aug-05 7:46 
Generalserver/client Pin
dap_qk31-Jul-05 14:46
dap_qk31-Jul-05 14:46 
GeneralRe: server/client Pin
Dave Kreskowiak1-Aug-05 7:33
mveDave Kreskowiak1-Aug-05 7:33 
GeneralCombo Box showing through my calendar Pin
clabrett31-Jul-05 13:21
clabrett31-Jul-05 13:21 
Generalproxy Pin
buzzbusy31-Jul-05 7:06
buzzbusy31-Jul-05 7:06 
GeneralRe: proxy Pin
Dave Kreskowiak31-Jul-05 19:21
mveDave Kreskowiak31-Jul-05 19:21 
Generalcapture keyboard Pin
buzzbusy31-Jul-05 7:01
buzzbusy31-Jul-05 7:01 
GeneralRe: capture keyboard Pin
nick1131-Jul-05 19:16
nick1131-Jul-05 19:16 
You have to use a global hook



'app.hInstance is this module '0 = all threads to it's global.

HookPtr = SetWindowsHookEx(WH_KEYBOARD_LL, AddressOf LowLevelKeyboardProc, App.hInstance, 0&)


Your LowLevelKeyBoardProcedure has to grab the raw data and then decode it.


Public Function LowLevelKeyboardProc(ByVal nCode As Long, ByVal WParam As Long, ByVal LParam As Long) As Long

Private Type KBDLLHOOKSTRUCT
vkCode As Long 'a virtual-key code in the range 1
'to 254
scanCode As Long 'hardware scan code for the key
Flags As Long 'specifies the extended-key flag,
'event-injected flag, context code,
'and transition-state flag
time As Long 'time stamp for this message
dwExtraInfo As Long 'extra info associated with the
'message
End Type

Dim KeyInfo As KBDLLHOOKSTRUCT

Call CopyMemory(KeyInfo, ByVal LParam, Len(KeyInfo))

'Now can grab the raw key code
KeyInfo.vkCode

Keep in mind there is an up key event and down key event. You want to do most of your processing on only on the down key event since that will allow you to grab CTL + Key or ALT + Key or Shift + Key combinations.

GeneralData base login prompt while loading Crystal report Pin
abhinish30-Jul-05 20:50
abhinish30-Jul-05 20:50 
GeneralHELP PRINTING HTML Pin
Alasiad30-Jul-05 17:58
Alasiad30-Jul-05 17:58 
GeneralValue lifetime Pin
erikkl200030-Jul-05 6:25
erikkl200030-Jul-05 6:25 
GeneralRe: Value lifetime Pin
Dave Kreskowiak1-Aug-05 7:31
mveDave Kreskowiak1-Aug-05 7:31 
Generalassignment grader Pin
mtate3230-Jul-05 5:19
mtate3230-Jul-05 5:19 
GeneralRe: assignment grader Pin
tazbird30-Jul-05 16:36
tazbird30-Jul-05 16:36 
GeneralRe: assignment grader Pin
mtate3231-Jul-05 6:11
mtate3231-Jul-05 6:11 
GeneralRe: assignment grader Pin
mtate3231-Jul-05 6:46
mtate3231-Jul-05 6:46 
GeneralRe: assignment grader Pin
mtate3231-Jul-05 6:44
mtate3231-Jul-05 6:44 
GeneralRe: assignment grader Pin
toppscrt1-Aug-05 18:32
toppscrt1-Aug-05 18:32 
GeneralRe: assignment grader Pin
mtate322-Aug-05 0:11
mtate322-Aug-05 0:11 
Generalu.are.u device linked with fingerprint recognition system in vb.net Pin
sscome30-Jul-05 3:29
sscome30-Jul-05 3:29 
GeneralRe: u.are.u device linked with fingerprint recognition system in vb.net Pin
Dave Kreskowiak31-Jul-05 19:17
mveDave Kreskowiak31-Jul-05 19:17 
GeneralForm Load and combobox Pin
Jodd30-Jul-05 1:23
Jodd30-Jul-05 1:23 
GeneralANSI & UNICODE Using VB 6 Pin
justzain29-Jul-05 22:19
justzain29-Jul-05 22:19 
Generalow to DragDrop a form with the mouse Pin
Member 195513229-Jul-05 20:39
Member 195513229-Jul-05 20:39 
GeneralRe: ow to DragDrop a form with the mouse Pin
Robert Rohde29-Jul-05 20:53
Robert Rohde29-Jul-05 20:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.