Capturing Joystick Input

Most of the code controlling the joystick is in the main window function. In the following portion of the message handler, the application calls joySetCapture to capture input from the joystick JOYSTICKID1.

case WM_CREATE:

if(joySetCapture(hWnd, JOYSTICKID1, NULL, FALSE))

{

MessageBeep(MB_ICONEXCLAMATION);

MessageBox(hWnd, "Couldn't capture the joystick.", NULL,

MB_OK | MB_ICONEXCLAMATION);

PostMessage(hWnd,WM_CLOSE,0,0L);

}

break;

Software for developers
Delphi Components
.Net Components
Software for Android Developers
More information resources
MegaDetailed.Net
Unix Manual Pages
Delphi Examples
Databases for Amazon shops developers
Amazon Categories Database
Browse Nodes Database