Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. MFC error

MFC error

Scheduled Pinned Locked Moved C / C++ / MFC
c++csharpvisual-studiodebugginghelp
5 Posts 2 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    BoudewijnEctor
    wrote on last edited by
    #1

    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

    A 1 Reply Last reply
    0
    • B BoudewijnEctor

      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

      A Offline
      A Offline
      Anthony_Yio
      wrote on last edited by
      #2

      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.

      B 1 Reply Last reply
      0
      • A Anthony_Yio

        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.

        B Offline
        B Offline
        BoudewijnEctor
        wrote on last edited by
        #3

        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:

        A 1 Reply Last reply
        0
        • B BoudewijnEctor

          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:

          A Offline
          A Offline
          Anthony_Yio
          wrote on last edited by
          #4

          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.

          B 1 Reply Last reply
          0
          • A Anthony_Yio

            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.

            B Offline
            B Offline
            BoudewijnEctor
            wrote on last edited by
            #5

            I can't trim the application anymore, It's already a standard app generated by a wizzard, so it has only minimal functionality

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups