[cpp]
[cpp] CSplitStr Split;
CString m_sText = "/123/456/789/";
Split.SetSplitFlag("/");
Split.SetSequenceAsOne(TRUE);
Split.SetData(m_sText);
CStringArray array;
Split.GetSplitStrArray(array);
int i = array.GetCount();
CString str = array[i-1];
AfxMessageBox(str);
CSplitStr Split;
CString m_sText = "/123/456/789/";
Split.SetSplitFlag("/");
Split.SetSequenceAsOne(TRUE);
Split.SetData(m_sText);
CStringArray array;
Split.GetSplitStrArray(array);
int i = array.GetCount();
CString str = array[i-1];
AfxMessageBox(str);
上面代碼,算是個測試例子