A:
'CString' to 'std::string':
Code:
CString cs("Hello" );
std::string s((LPCTSTR)cs);
'std::string' to 'CString':
Code:
std::string s("Hello" );
CString cs(s.c_str());
From : 转自: http://www.codeguru.com/forum/showthread.php?t=231155
CString cs("Hello" );
std::string s((LPCTSTR)cs);
std::string s("Hello" );
CString cs(s.c_str());
No comments:
Post a Comment