本文整理汇总了C++中_RecordsetPtr::Clone方法的典型用法代码示例。如果您正苦于以下问题:C++ _RecordsetPtr::Clone方法的具体用法?C++ _RecordsetPtr::Clone怎么用?C++ _RecordsetPtr::Clone使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类_RecordsetPtr
的用法示例。
在下文中一共展示了_RecordsetPtr::Clone方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: LoadFrom
BOOL CPagerChannel::LoadFrom(_RecordsetPtr xRecordset)
{
m_pRecordset = xRecordset->Clone( adLockOptimistic );
m_pRecordset->Filter = "xjsjbh = " + (_bstr_t)xRecordset->GetCollect("xjsjbh");
//_variant_t xjsjbh = m_pRecordset->GetCollect( "xjsjbh" );
// theApp.Message(MSG_ERROR,"---------->debug:[%i][%i] reccc=%i", m_nChan, xjsjbh.lVal,
// m_pRecordset->GetRecordCount());
CDialPacket* pPacket = new CDialPacket;
pPacket->SetLocalId( "96031222" );
_variant_t TheValue = m_pRecordset->GetCollect( "xPhoneNum" );
if ( VT_NULL == TheValue.vt ) pPacket->SetRemoteId( "" );
else pPacket->SetRemoteId( (LPCTSTR)(_bstr_t)TheValue );
TheValue = m_pRecordset->GetCollect( "xCaller" );
if ( VT_NULL == TheValue.vt ) pPacket->SetFeeNumber( "" );
else pPacket->SetFeeNumber( (LPCTSTR)(_bstr_t)TheValue );
CHAR xCallerId[MAX_PHONE + 1]; ZeroMemory(xCallerId, MAX_PHONE + 1);
pPacket->GetFeeNumber(xCallerId); pPacket->SetCallerId(xCallerId);
#if 1 // 重新指定计费号码
TheValue = m_pRecordset->GetCollect( "xFeeNumber" );
if ( VT_NULL != TheValue.vt ) pPacket->SetFeeNumber( (LPCTSTR)(_bstr_t)TheValue );
#endif
OnDialPacket( pPacket ); pPacket->Release();
#if 1
TheValue = m_pRecordset->GetCollect( "xPCMName" );
CString xUsrLvFile = (LPCTSTR)(_bstr_t)TheValue;
xUsrLvFile.TrimLeft(); xUsrLvFile.TrimRight();
CString xCallType = ReadPagerType( xUsrLvFile, CA_HOOK );
if ( xCallType.CompareNoCase(CallType) ) CopyMemory( CallType, (LPCTSTR)(xCallType), MAX_CALLTYPE );
//if ( IsMusic(pPager->UsrLvFile) ) CopyMemory( pPager->CallType, "BEST", MAX_CALLTYPE );
#endif
UpdateState( _PENDING_ );
m_bPending = TRUE;
return TRUE;
}