Jump to content
  • Advertisement
Sign in to follow this  
Unliterate

Incorrect undeclared identifier message??

This topic is 5058 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm try to use a INPUT and KEYBDINPUT structure from the winuser.h file (included by windows.h) but it keeps saying undeclared identifier, even though when I have INPUT Inputs; and type Inputs. , it shows me a list of the members?! I tried moving the lines that declare it out of the ifdef statements (right to the begining of the .h) but that didnt work either.. Any ideas?

Share this post


Link to post
Share on other sites
Advertisement
Could you post some code of where the problem is occurring? It might have nothing to do with the include files. It might purely be down to a scoping problem.

Post some relevant code and you'll be more likely to get a more helpful response. [smile]

Share this post


Link to post
Share on other sites
I know what the problem is. Do this where Windows.h is included:

#define _WIN32_WINNT 0x0500
#include <Windows.h>

I too had this bug, so I took a look at Windows.h and found that section of the file (with SendInput and related stuff) needed the above to be defined first. Kind of dumb but whatever.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!