cannot resolve symbol: method split, location: class java.lang.String
843838Dec 19 2005 — edited Dec 19 2005Hi,
Iam using J2SE1.4.2_10 version on my RedHat Entriprise linux and running tomcat5.0.28. I got the following error when I tried to execute the simple JSP program.
<%
java.lang.String str="a,b,c";
String arr[] = str.split(",");
for(int i=0;i<arr.length;i++)
out.println(arr);
%>
Error:
cannot resolve symbol symbol : method split (java.lang.String)
location: class java.lang.String String arr[] =str.split(",");
^
I dont want to use StringTokenizer.
Can anyone pls let meknow where Iam going wrong.
thanks in advance
Regards
Rao.,