- CString:MFC字符串
- string:STL字符串
- char *与CString的转换
//char * -> CString
char * p2 = "ccc";
CString str = CString(p3);
//CString -> char *
CStringA tmp;
tmp = str;
char *pp = tmp.GetBuffer();
-
CString和string之间转换要用char* 做桥梁
-
string 与 char*的转换 用 .c_str();
网友评论