string--->CString
#ifdef UNICODE
#define Tstring wstring
#else
#define Tstring string
#endif
可以这样转换
CString str=CString(string.c_str())
const char*----->LPCWSTR
const char *str;
CString temp = str;
LPCWSTR app = (LPCWSTR)(temp.AllocSysString());
时间: 2024-11-05 20:25:52