Dear, You're can write: String str = "Anne Gomez ; 5th Avenue ;;925 NY ; 1978/10/11"; System.out.println(str.substring(0, str.indexOf(";", 1))); System.out.println(str.substring(str.indexOf(";", 1) + 1, str.lastIndexOf(";"))); System.out.println(str.substring(str.lastIndexOf(";") + 1));
2010/9/25 jitesh dundas <jbdun...@gmail.com> > Yes, > > define a constructor or method that takes your input string.. > > Then loop through each line and serch for ';' .best would be toput > thay in array string.. > > jd > > On 9/24/10, Santana <paulito.sant...@gmail.com> wrote: > > Hi all, > > i'am newbie in JAVA and i would liked your point of views/opinion for > > the following situation : > > > > i have a file with some lines that presents this format of > > information : > > > > .... > > Anne Gomez ; "5th Avenue ;";"925 NY " ; 1978/10/11 > > ... > > > > the ";" is the separator of fields and i know the folling : > > > > > > 1ªfield = Anne Gomez > > 2ªfield = 5th Avenue ;";"925 NY > > 3ªfield = 1978/10/11 > > > > > > The 2º field presents as value one or several semin-colon(";") and one > > or several single quote. Do you think there is possbile with class to > > extract the fields as i describe previous ? > > > > Regards, > > Paulito Santana > > > > -- > > You received this message because you are subscribed to the Google > > Groups "Java EE (J2EE) Programming with Passion!" group. > > To post to this group, send email to > > java-ee-j2ee-programming-with-passion@googlegroups.com > > To unsubscribe from this group, send email to > > java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com<java-ee-j2ee-programming-with-passion%2bunsubscr...@googlegroups.com> > > For more options, visit this group at > > > http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en > > -- > You received this message because you are subscribed to the Google > Groups "Java EE (J2EE) Programming with Passion!" group. > To post to this group, send email to > java-ee-j2ee-programming-with-passion@googlegroups.com > To unsubscribe from this group, send email to > java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com<java-ee-j2ee-programming-with-passion%2bunsubscr...@googlegroups.com> > For more options, visit this group at > > http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en > -- Name: Nguyễn Văn Vinh Phone: 01686417702 Email:vinhnv...@gmail.com Email2:vin...@gameso.vn <email2%3avin...@gameso.vn> Yahoo:hoangtusoyeu...@yahoo.com <yahoo%3ahoangtusoyeu...@yahoo.com> -- You received this message because you are subscribed to the Google Groups "Java EE (J2EE) Programming with Passion!" group. To post to this group, send email to java-ee-j2ee-programming-with-passion@googlegroups.com To unsubscribe from this group, send email to java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en