Re: SendInput won't compile
I moved the #define _WIN32_WINNT into the "stdafx.h" file before the MFC
headers and that seems to solve the problem. Thanks! But now the compiler
found 2 undeclared identifiers
Here is the code:
void CMimicMouseClickDlg::OnTimer(UINT nIDEvent)
// TODO: Add your message handler code here and/or call default
I searched the winuser.h and they are not defined there! I am using Visual
Studio 6 service pack 6.
"Joseph M. Newcomer" <firstname.lastname@example.org>
Not sure why you think 0x0501 is going to change ANYTHING, since this was
Windows NT 4.0 SP 3. So pretty much any setting is going to work!
Even the most casual inspection of the header file shows that this is
_WIN32_WINNT > 0x0400. I believe the default values are already greater
Of course, I'm assuming that you did this definition in stdafx.h, BEFORE
any of the
Windows or MFC header files were included!
Telling us you "defined" it conveys no useful information; knowing WHERE
you defined it
matters a lot! And, of course, you did not mention which version of VS
you were using;
some versions define this symbol in another header file, so if you did
your own #define,
it will be modified by the header file produced by VS.
Show your stdafx.h and where you defined it!
Since you did not say WHERE you defined it, or given any error messages,
it is hard to
guess what is going on here. If you defined it anywhere OTHER than in
stdafx.h, then it
didn't do anything!
On Tue, 20 Apr 2010 01:07:57 +0800, "dave" <email@example.com> wrote:
Hi, I try to use the sendinput() function to fire mouse events, but it
compile even after I defined the _WIN32_WINNT as 0x0501. Why is that?
Thanks a bunch.
Joseph M. Newcomer [MVP]
MVP Tips: http://www.flounder.com/mvp_tips.htm