wood burning stoves*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Split String by $ Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Split String by $" Watch "Split String by $" New topic
Author

Split String by $

Tusshar Fasate
Ranch Hand

Joined: May 21, 2008
Posts: 81
Hi,
I am trying to split a string by $ ..but I am not getting desirable output.
here is my code..


output:
Hello
strArr:0 element ->Fri Jul 16 16:01:23 IST 2010 $ sds
Run successfully..


Please help me out on this.
Thanks..
Tusshar Fasate
Ranch Hand

Joined: May 21, 2008
Posts: 81
one small correction ..

String strArr[]=str.trim().split("$");
instread of this // String strArr[]=str.trim().split("//$");


please help me.
Martin Vanyavchich
Ranch Hand

Joined: Sep 16, 2008
Posts: 241
Wrong slashes try


SCJP 6, OCMJD 6, OCPJWSD 6
I no good English.
Pramod P Deore
Ranch Hand

Joined: Jul 15, 2008
Posts: 629

Try this one
>


Life is easy because we write the source code.....
Tusshar Fasate
Ranch Hand

Joined: May 21, 2008
Posts: 81
Thanks a lot Pramod and Martin for your quick reply...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Split String by $