char* convertCStringToChars(CString string) { int nLength=string.GetLength(); char *c=new char[nLength+1]; memset(c,0,nLength+1); WideCharToMultiByte(CP_ACP,0,string,nLength,c,nLength,NULL,NULL); return c; }
转载于:https://www.cnblogs.com/tt2015-sz/p/4656782.html