TextBuffer buffer;
str value;
Counter cnt;
value = "1212-43434-3434-64545";
buffer = new TextBuffer();
buffer.setText(value);
while (buffer.nextToken(0, '-'))
{
cnt++;
if(cnt == 1)
info (strFmt("first %1",buffer.token()));
if(cnt == 2)
info (strFmt("two %1",buffer.token()));
if(cnt == 3)
info (strFmt("three %1",buffer.token()));
if(cnt == 4)
info (strFmt("four %1",buffer.token()));
}
Comments