06 2012 档案
摘要:MFC中,使用Edit控件显示中文遇到乱码。自己写了两个函数进行转化 1 // CString转换成string 2 string CDictDlg::CString2string(CString &str) 3 { 4 char *pCh = new char[MY_EDIT_TEXT_LENG]; 5 // W(2B) -> A(B) 6 WideCharToMultiByte(CP_ACP, 0, str.GetBuffer(), -1, pCh, str.GetLength() * 2, NULL, NULL); 7 pCh[str.GetLength(...
        阅读全文
                
 
                    
                
 浙公网安备 33010602011771号
浙公网安备 33010602011771号