作者thomas2005 (无)
看板Programming
标题[问题] XP 32 bit 转 64 bit 设疑问
时间Mon Mar 8 18:29:24 2010
想请教一下各位。
目前我正在写一个程式。目前要开发 XP 32,64 bit 程式。
目前在 64 bit 开发遇到底下这种问题。
我将 XP 32 bit程式直接拿到 XP 64bit。使用 Visual Studio 2005。设成 x64 环境。
结果都发生以下这类型态的问题。但在 Vista & Win 7 都能正常编译。
请问有什麽设定可以设定?
或是我真的要一个一个解。
谢谢。
wchar_t chKey[100];
retCode = RegenumKeyEx(hKey, i, chKey, &dwSize, NULL, NULL, NULL, NULL);
error C2664: 'RegenumKeyExA' : cannot convert parameter 3 from 'wchar_t
[100]' to 'LPSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast,
C-style cast or function-style cast
----------------------------------------------------------------------------------------------------------------------
Tchar const c_szAttachedTo[] = L"AttachedTo";
error C2440: 'initializing' : cannot convert from 'const wchar_t [11]' to
'const Tchar []'
1> There is no context in which this conversion is possible
----------------------------------------------------------------------------------------------------------------------
wchar_t szInfPath[100];
CString Infpath;
wcscpy(szInfPath , Infpath);
warning C4995: 'wcscpy': name was marked as #pragma deprecated
1>.\TestDlg.cpp(1140) : error C2664: 'wcscpy' : cannot convert parameter 2
from 'CString' to 'const wchar_t *'
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 122.146.103.174
1F:→ adrianshum:应该和 32bit/64bit 无关. 是 UNICODE 61.238.156.189 03/08 19:33
2F:→ adrianshum:和 MCBS 的问题 61.238.156.189 03/08 19:33
3F:→ thomas2005:感谢。已经解决 60.244.105.125 03/09 11:16