A few users have been asking for ways to check keypresses and get scancodes etc..
I've written this small program to operate in Windows, so if you compile it, you can use the exe to run in the background while working on your other "Keyboard" projects.
Rem Project: KeyboardScancodes
Rem Created: 24/06/03 15:14:01
Rem Author: Bloodshot
Rem **************************************************************************************************************************
Rem ************************************************** Initialisation ****************************************************
Rem **************************************************************************************************************************
Rem Make this program run in Windows mode, so it can be used in the background while working on other DB projects!
Set Window On
Set Window Title "Keyboard Scancodes"
Set Window Layout 1,1,1
Set Window Size 640,400
Set Window Position 160,120
Sync On : CLS 0 : Sync
Rem Next two lines allow you to scan Esc and system keys without interference
Disable EscapeKey
Disable SystemKeys
Set Text Font "arial" : Set Text Size 24
Set Text to Bold : Set Text Transparent
Ink RGB(255,255,255),RGB(0,0,0) : Center Text 320,1*(Text Size()),"Press any key to get it's scancode value"
Ink RGB(127,127,159),RGB(0,0,0) : Center Text 320,2*(Text Size()),"(Press both Left & Right Mouse buttons together, to quit)"
Sync
Rem **************************************************************************************************************************
Rem ***************************************************** Main Loop ******************************************************
Rem **************************************************************************************************************************
OLDKEY=0 : NEWKEY=0 : MOUSE=0
Repeat
NEWKEY=Scancode()
Rem Only update the screen when a new key has been pressed
If NEWKEY>0 and NEWKEYOLDKEY
Rem Erase the last line of text first, before overwriting
Set Cursor 0,40 : Ink RGB(0,0,0),RGB(0,0,0) : Center Text 320,5*(Text Size()),"The Scancode Value for the key you pressed = "+Str$(OLDKEY)
Rem Now Show the result
Set Cursor 0,40 : Ink RGB(255,255,0),RGB(0,0,0) : Center Text 320,5*(Text Size()),"The Scancode Value for the key you pressed = "+Str$(NEWKEY)
Sync
OLDKEY=NEWKEY
EndIf
MOUSE=MouseClick()
Until MOUSE>2
Rem **************************************************************************************************************************
Rem **************************************************** Termination *****************************************************
Rem **************************************************************************************************************************
CLS 0 : Sync
Ink RGB(255,255,255),RGB(0,0,0) : Center Text 320,1*(Text Size()),"Terminating program..."
Sync : Wait 1000
Rem Tidy Up - Return DBPro to its initial state
Enable EscapeKey
Enable SystemKeys
Sync Off
Set Window Off
You get a 30 day trial, after which you must pay me $200 for the Product key!