MFC error
-
Hi, I'm trying to write an MFC application in VS.NET2003, I've changed nothing in the wizzard wich will be displayed after choosing project name and type etc. After pressing "finish" in the wizzard I pressed CTRL+SHIFT+B ("build"), expecting everything would be fine. IT WASN'T: ------ Build started: Project: mfc2, Configuration: Debug Win32 ------ Compiling... stdafx.cpp c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxv_w32.h(230) : error C2065: 'DWORD_PTR' : undeclared identifier c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxv_w32.h(230) : error C2143: syntax error : missing ';' before 'GetWindowThreadProcessId' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2061: syntax error : identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2146: syntax error : missing '(' before identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2061: syntax error : identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2146: syntax error : missing '(' before identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(29) : error C2143: syntax error : missing ';' before '__stdcall' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(29) : error C2501: 'DWORD_PTR' : missing storage-class or type specifiers c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : error C2146: syntax error : missing ')' before identifier 'dwProcess' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : warning C4229: anachronism used : modifiers on data are ignored c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : error C2182: 'AtlTraceCloseProcess' : illegal use of type 'void' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : error C2059: syntax error : ')' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(31) : error C2146: syntax error : missing ')' before identifier 'dwProcess' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(31) : warning C4229: anachronism used : modifiers on data are ignored c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atl
-
Hi, I'm trying to write an MFC application in VS.NET2003, I've changed nothing in the wizzard wich will be displayed after choosing project name and type etc. After pressing "finish" in the wizzard I pressed CTRL+SHIFT+B ("build"), expecting everything would be fine. IT WASN'T: ------ Build started: Project: mfc2, Configuration: Debug Win32 ------ Compiling... stdafx.cpp c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxv_w32.h(230) : error C2065: 'DWORD_PTR' : undeclared identifier c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\afxv_w32.h(230) : error C2143: syntax error : missing ';' before 'GetWindowThreadProcessId' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2061: syntax error : identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2146: syntax error : missing '(' before identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2061: syntax error : identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlconv.h(92) : error C2146: syntax error : missing '(' before identifier 'LONG_PTR' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(29) : error C2143: syntax error : missing ';' before '__stdcall' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(29) : error C2501: 'DWORD_PTR' : missing storage-class or type specifiers c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : error C2146: syntax error : missing ')' before identifier 'dwProcess' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : warning C4229: anachronism used : modifiers on data are ignored c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : error C2182: 'AtlTraceCloseProcess' : illegal use of type 'void' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(30) : error C2059: syntax error : ')' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(31) : error C2146: syntax error : missing ')' before identifier 'dwProcess' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atldebugapi.h(31) : warning C4229: anachronism used : modifiers on data are ignored c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\atl
Not sure this gonna help. Try to include in your header. #include <atlstr.h> // CString support. #include <atltypes.h> // CPoint, CRect, CSize support. there are many good articles in codeproject which demonstrate the porting.
-
Not sure this gonna help. Try to include in your header. #include <atlstr.h> // CString support. #include <atltypes.h> // CPoint, CRect, CSize support. there are many good articles in codeproject which demonstrate the porting.
Ok thanks,:) But, when I now complete the wizzard, a messagebox is shown with error rc2104: undefined keyword or name: ds_shellfont what is this?:confused:
-
Ok thanks,:) But, when I now complete the wizzard, a messagebox is shown with error rc2104: undefined keyword or name: ds_shellfont what is this?:confused:
I am not sure what is ds_shellfont. But my suggestion is, you should trim your app to smaller chunk to see what is missing. Although Ms provide IjW to convert your VC6 to VC7 but it is not a magic. From what I had learned in codeproject. VC7 do conversion by supplying ATL to replace your old MFC classes. The two header I suggested are ATL header.
-
I am not sure what is ds_shellfont. But my suggestion is, you should trim your app to smaller chunk to see what is missing. Although Ms provide IjW to convert your VC6 to VC7 but it is not a magic. From what I had learned in codeproject. VC7 do conversion by supplying ATL to replace your old MFC classes. The two header I suggested are ATL header.
I can't trim the application anymore, It's already a standard app generated by a wizzard, so it has only minimal functionality