Please help me with string tokanize. my input file is text file such as
1,xyz,1 HP-1 Sigma,1.0,Y,Single,,
2,dfg,32 KES LW0090 ,1.0,Y,Single,,
with this code I am getting assertion
iStart>=0
and only one string.(except 1)
xyz,1 HP-1 Sigma,1.0,Y,Single
this string
my code :
if(File.Open(pathName, CFile::modeRead)) {
while(File.ReadString(strLine)) {
int Position = 0;
CString Token;
Token = strLine.Tokenize(",", Position);
while(Token!=" ")
{
int total = (int)m_List2.GetItemCount();
for ( int ii=0; ii< total; ii++ ) {
for(int j=0; j<=6;j++) {
CString Token=strLine.Tokenize(",",Position);
m_List2.SetItemText(ii,j,Token);
}
}
}
}
}