4,011
社区成员
发帖
与我相关
我的任务
分享
try
{
sql.Format("select count(*) as BuyTotal from BuyInformation where 用户编号 = '%s'",itemStr);
pCommand->ActiveConnection = CGlobal::pConn;
pCommand->CommandText = (_bstr_t)sql;
pRecordset = pCommand->Execute(NULL,NULL,adCmdText);
}
catch(_com_error e)
{
MessageBox("数据库错误:\r\n" + e.Description(),"系统提示",MB_OK|MB_ICONERROR);
return;
}
for (int i=0;i<6;i++)
{
sscanf_s(itemStr.Mid(2*i,2),"%x",&UserID[i]);
}