vs2003项目转换成vs2010项目常出错误

http://forums.codeguru.com/archive/index.php/t-380568.html

I Managed to locate the shortcut to activate this SDK with windows. So all goes well untill.....

Please find at the botton the errors I get when I use the
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0501
#endif

As you can see I no longer get LVINSERTMARK and GetInsertMark errors, but MFC spits the dummy over PSCROLLBARINFO and CCM_SETWINDOWTHEME.

Has anybody got any ideas here about what to do?

Thankyou,
Jonathan.

c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin.h(3289): error C2061: syntax error : identifier 'PSCROLLBARINFO'
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin4.inl(148): error C2065: 'PSCROLLBARINFO' : undeclared identifier
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin4.inl(148): error C2146: syntax error : missing ')' before identifier 'pScrollInfo'
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin4.inl(148): error C2761: 'BOOL CScrollBar::GetScrollBarInfo(void) const' : member function redeclaration not allowed
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin4.inl(148): error C2059: syntax error : ')'
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin4.inl(149): error C2143: syntax error : missing ';' before '{'
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxwin4.inl(149): error C2447: '{' : missing function header (old-style formal list?)
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxcmn3.inl(18): error C2065: 'CCM_SETWINDOWTHEME' : undeclared identifier
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxcmn3.inl(21): error C3861: 'CCM_SETWINDOWTHEME': identifier not found, even with argument-dependent lookup
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxcmn3.inl(27): error C3861: 'CCM_SETWINDOWTHEME': identifier not found, even with argument-dependent lookup
c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxcmn3.inl(44): error C3861: 'CCM_SETWINDOWTHEME': identifier not found, even with argument-dependent lookup

gregmiller01
October 8th, 2009, 06:07 PM
I realize this thread is 3 1/2 years old, but after searching for this error:
"error C3861: 'CCM_SETWINDOWTHEME': identifier not found, even with argument-dependent lookup" and finding no solution I figured that I might not be the last one to experience this. My problem started when I wanted to use the LVS_EX_DOUBLEBUFFER flag in a CListCtrl.

To fix this problem, make your stdafx.h file look like this:

// Modify the following defines if you have to target a platform prior to the ones specified below.
// Refer to MSDN for the latest info on corresponding values for different platforms.
#ifndef WINVER // Allow use of features specific to Windows 95 and Windows NT 4 or later.
#define WINVER 0x0501 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
#endif

#ifndef _WIN32_WINNT // Allow use of features specific to Windows NT 4 or later.
#define _WIN32_WINNT 0x0501 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
#endif

#ifndef _WIN32_WINDOWS // Allow use of features specific to Windows 98 or later.
#define _WIN32_WINDOWS 0x0501 // Change this to the appropriate value to target Windows Me or later.
#endif

#ifndef _WIN32_IE // Allow use of features specific to IE 4.0 or later.
#define _WIN32_IE 0x0500 // Change this to the appropriate value to target IE 5.0 or later.
#endif
 
或者在c/c++预处理器中定义

你可能感兴趣的:(window,2010,microsoft,include,windows,.net,features)