aspose file tools*
The moose likes Beginning Java and the fly likes method (replaceAll) of String Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "method (replaceAll) of String" Watch "method (replaceAll) of String" New topic
Author

method (replaceAll) of String

viral trivedi
Greenhorn

Joined: Apr 24, 2003
Posts: 3
I get an error message when i compile my program on an unix. In windows it works.
I am using method replaceAll of String and i get
an error mesage cannot resolve symbol or method not found Can someone help?
[ May 07, 2003: Message edited by: viral trivedi ]
Thomas Paul
mister krabs
Ranch Hand

Joined: May 05, 2000
Posts: 13974
Probably a version issue. replaceAll() was added to the String class in version 1.4 of the JDK. What version are you running on Unix?


Associate Instructor - Hofstra University
Amazon Top 750 reviewer - Blog - Unresolved References - Book Review Blog
Joel McNary
Bartender

Joined: Aug 20, 2001
Posts: 1817

What are the versions of the JDKs that you are using? I would hazard a guess that the Windows version is an older one. .replaceAll() didn't exist until the advent of regular expressions in Java (Version 1.4, methinks)


Piscis Babelis est parvus, flavus, et hiridicus, et est probabiliter insolitissima raritas in toto mundo.
viral trivedi
Greenhorn

Joined: Apr 24, 2003
Posts: 3
Thank you, Windows was having 1.4 while Unix has
1.3
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: method (replaceAll) of String