摘要: 1.头文件中要定义宏;
#define UNICODE
#define _UNICODE
////////////////////
char buf[128];
memset(buf,0,128);
strcpy(buf,"你好");
WCHAR pCName[128];
memset(pCName,0,128);
MultiByteToWideChar(CP_THREAD_ACP,MB_USEGLYPHCHARS,buf,strlen(buf),pCName,128);
至于WCHAR 转换到CHAR,则用
WideCharToMultiByte
//////////////////////////
2.char转换成wchar
const char *pFilePathName = "c:\\aa.dll";
int nLen = s阅读全文
posted @ 2008-09-25 12:01 黄美华 阅读(1567) | 评论 (0) 编辑 |
