Joystick in background

Last post 04-07-2008, 4:23 AM by petercyyau. 0 replies.
Sort Posts: Previous Next
  •  04-07-2008, 4:23 AM

    Joystick in background

    Dear all,

    I made a program to detect the joystick action, simple use only up down left and right.
    I succesfully copy a demo code from Direct X Sample Library.

    Question: How to modify the code to make the program detect the
    joystick in background? i.e. if the windows (my program) is not in
    focus. How to make my program keep detect the joystick action?

    after tracking my code, I found that the error case at
    applicationDevice.Poll()
    where applicationDevice=joystick.

    in normal situtaion, if my appliction windows on focus, this statement run correctly and get most update joystick input info when the windows loss focus, the Poll() throw exception any hitns to fix this so that even the windows loss focus, poll can still get the data from joystick?

    thanks
    P
View as RSS news feed in XML
©2007 Microsoft Corporation. All rights reserved. Privacy Statement Terms of Use Code of Conduct Feedback