1 Reply Latest reply on Nov 7, 2010 5:33 AM by tanq

    Build error on ATI Stream examples, is this a bug?

    P3ndldqny2
      error C2664: 'SetWindowTextA' : cannot convert parameter 2 from 'LPCWSTR' to 'LPCSTR'

      Error 1 error C2664: 'SetWindowTextA' : cannot convert parameter 2 from 'LPCWSTR' to 'LPCSTR' C:\Users\Rob\Documents\ATI Stream\samples\opencl\cl\app\SimpleDX10\SimpleDX10.cpp 399 1 SimpleDX10VS10

      Error 2 error C2440: 'initializing' : cannot convert from 'LPCWSTR' to 'LPCSTR' C:\Users\Rob\Documents\ATI Stream\samples\opencl\cl\app\SimpleDX10\SimpleDX10.cpp 1396 1 SimpleDX10VS10

      Error 3 error C2664: 'CreateWindowExA' : cannot convert parameter 2 from 'LPCWSTR' to 'LPCSTR' C:\Users\Rob\Documents\ATI Stream\samples\opencl\cl\app\SimpleDX10\SimpleDX10.cpp 1413 1 SimpleDX10VS10

      Error 4 error C2664: 'UnregisterClassA' : cannot convert parameter 1 from 'LPCWSTR' to 'LPCSTR' C:\Users\Rob\Documents\ATI Stream\samples\opencl\cl\app\SimpleDX10\SimpleDX10.cpp 1442 1 SimpleDX10VS10

      Anybody know what the issue is? I downloaded the directX SDK, windows SDK and (obviously) ATI Stream SDK....

        • Build error on ATI Stream examples, is this a bug?
          tanq

          You mixed unicode and non-unicode definitions. LPCWSTR defined as wchar_t and it works woth SetWindowTextW. SetWindowTextA is ASCII function and it works with char. Check macro definitions for _UNICODE and the like. You have to switch on all that macros, including _UNICODE __UNICODE UNICODE and may be something else, or switch all them off.