Hello,
Here is the code that can help you, just go through it
Code:
private List <String> spwtdel(String str, String OPENLiMiT, String closeLimit)
{
List lt = <String> new ArrayList <String>();
int froplm = str.indexOf(OPENLiMiT);
int frcllm = str.indexOf(closeLimit, froplm);
while ((froplm! = -1) && (frcllm! = -1))
{
if (froplm> 0)
lt.add(str.substring(0, FirstOpenLimit));
lt.add(str.substring(froplm, frcllm + 1));
if (frcllm <str.length())
str = str.substring(frcllm + 1, Str.length());
else
str = "";
froplm = str.indexOf(OPENLiMiT);
frcllm = str.indexOf(closeLimit, froplm);
}
if (str.length() > 0)
lt.add(str);
return lt;
}
Bookmarks