ANSI ---> UNICODE

工程的編碼問題,你工程選擇的是Unicode編碼的吧。換成多字節編碼應該就沒有問題了,或者向下面這樣修改:

錯誤 3 error C2664: “strlen”: 不能將參數 1 從“CString”轉換爲“const char *”
---------------------------------------------------
strlen() -> _tcslen()

錯誤 4 error C2664: “strcpy”: 不能將參數 2 從“CString”轉換爲“const char *”
-------------------------------------------
strcpy() -> _tcscpy();

錯誤 5 error C2039: “PostMessageA”: 不是“CWnd”的成員
PostMessageA() -> PostMessage();

錯誤 8 error C2664: “_mkdir”: 不能將參數 1 從“const wchar_t [18]”轉換爲“const char *”
_mkdir() -> _tmkdir();

錯誤 9 error C2664: “atoi”: 不能將參數 1 從“ATL::CStringT<BaseType,StringTraits>”轉換爲“const char *”
atoi() -> _ttoi();

錯誤 10 error C2664: “atoi”: 不能將參數 1 從“ATL::CStringT<BaseType,StringTraits>”轉換爲“const char *”
atoi() -> _ttoi();

錯誤 11 error C2664: “atoi”: 不能將參數 1 從“ATL::CStringT<BaseType,StringTraits>”轉換爲“const char *”
atoi() -> _ttoi();

錯誤 12 error C2664: “atoi”: 不能將參數 1 從“ATL::CStringT<BaseType,StringTraits>”轉換爲“const char *”
atoi() -> _ttoi();

錯誤 13 error C2664: “_mkdir”: 不能將參數 1 從“const wchar_t [18]”轉換爲“const char *”
_mkdir() -> _tmkdir();

錯誤 16 error C2664: “void ATL::CStringT<BaseType,StringTraits>::Format(const wchar_t *,...)”: 不能將參數 1 從“const char [3]”轉換爲“const wchar_t *”
Format(“..”,...) -> Format(_T("...", ...);

錯誤 17 error C2664: “void ATL::CStringT<BaseType,StringTraits>::Format(const wchar_t *,...)”: 不能將參數 1 從“const char [3]”轉換爲“const wchar_t *”
Format(“..”,...) -> Format(_T("...", ...);

錯誤 18 error C2664: “void ATL::CStringT<BaseType,StringTraits>::Format(const wchar_t *,...)”: 不能將參數 1 從“const char [3]”轉換爲“const wchar_t *”
Format(“..”,...) -> Format(_T("...", ...);

錯誤 19 error C2664: “void ATL::CStringT<BaseType,StringTraits>::Format(const wchar_t *,...)”: 不能將參數 1 從“const char [3]”轉換爲“const wchar_t *”
Format(“..”,...) -> Format(_T("...", ...);
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章