-extern "C" {
-#ifdef __VISUALC__
-// If you use the wxDbCreateDataSource() function with MSW/VC6,
-// you cannot use the iODBC headers, you must use the VC headers,
-// plus the odbcinst.h header - gt Nov 2 2000
-//
-// Must add "odbccp32.lib" in \wx2\wxWindows\src\makevc.env to the WINLIBS= line
-//
+#include "wx/defs.h"
+#include "wx/string.h"
+
+#if defined(__VISUALC__)
+ // we need to include standard Windows headers but we can't include
+ // <windows.h> directly when using MFC because it includes it itself in a
+ // different manner
+ #if wxUSE_MFC
+ #include <afxwin.h>
+ #else // !wxUSE_MFC
+ #ifndef STRICT
+ #define STRICT 1
+ #endif
+
+ #include <windows.h>
+ #include "wx/msw/winundef.h"
+ #endif // wxUSE_MFC/!wxUSE_MFC
+
+ // If you use the wxDbCreateDataSource() function with MSW/VC6,
+ // you cannot use the iODBC headers, you must use the VC headers,
+ // plus the odbcinst.h header - gt Nov 2 2000
+ //
+ // Must add "odbccp32.lib" in \wx2\wxWindows\src\makevc.env to the WINLIBS= line
+ //