15,979
社区成员
发帖
与我相关
我的任务
分享
你好,请问你找到这种图是用什么工具绘制了吗?
/// <类型>Fanction</类型>
/// <作者>Mr. Hu</作者>
/// <日期>20181109</日期>
/// <名称>getJosn</名称>
/// <参数 name = "strName">数据关键字</参数>
/// <参数 name = "strResult">返回结果</参数>
/// <返回>TURE 成功,FALSE 失败</返回>
/// <说明>返回关键字对应的数据,可能是0长度字符串,匹配无效时,保留原数据</说明>
BOOL getJosn(LPCTSTR strName, CString & strResult)
{
CString str;
str.Format(L".*`%s\\(DBVT_STRING\\)`:\\s(.*?)(;\\s`.*|$)", strName);
std::wregex rx(str); // 如果是unicode码时,用wregex和wstring;
if (regex_match(m_strSource, mr, rx)) // ?? 写成这种形式regex_match(std::wstring(str), mr, rx),运行时出错。
{
strResult = mr[1].str().c_str(); // mr[0]是全部字符串,mr[1]是匹配的第一个字符串。
return TRUE;
}
return FALSE;
}