1.定义结构体类型的vector
typedef struct _LABEL_VECTOR_
{
DWORD m_id;
CString m_sender;
CString m_receiver;
CString m_content;
unsigned int m_len;
CString m_time;
}LABLE_VECTOR;
typedef vector<LABLE_VECTOR> VECTOR_LABLE;
2.存储此种类型的数据
<pre name="code" class="cpp"> xLableStruct.m_id = it->at(0);
xLableStruct.m_sender= it->at(1);
xLableStruct.m_receiver=it->at(2);
xLableStruct.m_content= it->at(3);
xLableStruct.m_len= it->at(4);
xLableStruct.m_time= it->at(5);
m_xVectorLable.push_back(xLableStruct);
3.取出第n个元素中的m_time值
VECTOR_LABLE::iterator it;
it = m_xVectorLable.begin();
it += n;
CStsing tim = it->m_time;