wince6.0 下win32 api 写的代码。
char inFilename[128];
memset(inFilename, 0x00, sizeof(inFilename));
wcscpy(inFilename,_T("\\Temp\\test_420_1599_1198.jpg"));
DNW串口打印消息:
RETAILMSG(1,(TEXT("[RETAILMSG] inFilename : %s\n"),inFilename));
printf("[printf] inFilename : %s \n", inFilename);
消息结果是:
[RETAILMSG] inFilename : \Temp\test_420_1599_1198.jpg
[printf] inFilename : \
------解决方案--------------------
inFilename 是wchar_t的
printf 应该用char的
用_wprintf