阅读背景:

string中的字符串是blob转换成string类型

来源:互联网 
string CAndroidSoma::GetContent( string &strAttInfo)
{	
	/*const char * strTmp=strAttInfo.c_str();
	CString StrData(strTmp);*/
	strAttInfo=phstr_replaceString(strAttInfo,"[","");
	strAttInfo=phstr_replaceString(strAttInfo,"]","");

    CString strTmp;
  
    int iPos=0;
    byte* pBuffer=new byte[(int)strAttInfo.length()+1];
	memset(pBuffer,0,(int)strAttInfo.length()+1);
	while(AfxExtractSubString(strTmp,ph_convertFromUTF8(strAttInfo).c_str(),iPos,','))
    {
        iPos++;
		string strTemp= ph_convertToUTF8(strTmp).c_str();
		byte Temp=atoi(strTemp.c_str());
		pBuffer[iPos-1]=Temp;

       // vecString.push_back(strTmp);
		
    }   

	CString StrResult(pBuffer);
	string ss = ph_convertToUTF8(StrResult).c_str();
	return ss;
	
}string CAndroidSoma::GetContent( string &strAtt



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: