使用vs2008 的OutputDebugString 时编译产生的错误
2013-10-10 14:52
495 查看
错误信息:
1. 中文版
“OutputDebugStringW”: 不能将参数 1 从“const char [18]”转换为“LPCWSTR”
2. 英文版
'OutputDebugStringW' : cannot convert parameter 1 from 'char [100]' to 'LPCWSTR'
原因:
OutputDebugString默认是Unicode方式,会变成OutputDebugStringW。
解决:
如果想用ANSI版本的,直接写OutputDebugStringA,或者设置工程属性,使用MBCS的编码集。
other: 这个错误的解决办法用中文还真难找。
1. 中文版
“OutputDebugStringW”: 不能将参数 1 从“const char [18]”转换为“LPCWSTR”
2. 英文版
'OutputDebugStringW' : cannot convert parameter 1 from 'char [100]' to 'LPCWSTR'
原因:
OutputDebugString默认是Unicode方式,会变成OutputDebugStringW。
解决:
如果想用ANSI版本的,直接写OutputDebugStringA,或者设置工程属性,使用MBCS的编码集。
other: 这个错误的解决办法用中文还真难找。
相关文章推荐
- 使用OutputDebugString将调试信息输出
- 使用OutputDebugString帮助调试
- _CrtDbgReport: String too long or IO Error错误的产生情况和处理 使用setlocale函数
- Qt中QString对象使用toStdString().data()会产生错误
- 使用OutputDebugString将调试信息输出
- 使用OutputDebugString帮助调试
- 服务程序使用OutputDebugString,DbgView接收不到调试信息问题
- 使用OutputDebugString将调试信息输出
- 使用OutputDebugString将调试信息输出
- Debug编译运行都没有问题,Release编译错误error C2664: 'ATL::CStringT<BaseType,StringTraits>::CStringT(const VARIANT
- 使用gcc -g编译,gdb调试时仍然存在“no debug symbols found”的错误
- 关于qt中使用ico文件做程序图标时编译报debug/myico_res.o Error 1错误的说明
- Windows日志打印API的封装使用OutputDebugStringA
- win32使用OutputDebugString输出调试信息的方法
- 使用OutputDebugString调试窗口程序
- 使用gcc -g编译,gdb调试时仍然存在“no debug symbols found”的错误
- 使用OutputDebugString做调试输出
- 使用OutputDebugString帮助调试
- 关于qt中使用ico文件做程序图标时编译报debug/myico_res.o Error 1错误的说明
- 安卓编译错误app:compileDebugJavaWithJavac>Compilation failed; see the compiler error output for details.