• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

StringTokenizer Class not Found

 
Adam Polak
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have created an abstract class in wich I want to use StringTokenizer. However when I want to compile it it says that the class StringTokenizer can't be found.
The whole abstract class can be found at: http://www.hio.ft.hanze.nl/dori/Strings/Cipher.htm
Offcourse when I put it in an Applet I don't name it public class.
 
Andee Weir
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For what it's worth I took your code & put in Websphere studio - it had no problem compiling (except for your decrypt method not returning a String).
Andee
 
Gabriel White
Ranch Hand
Posts: 233
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I used borland j builder and I used the same import command and I had no problems bro.
Is this a program that you cut and pasted from another? I have seen some compilers have problems with that. You may want to just open up a new package and start a new class with the same import command and see if it recognizes the StringTokenizer command.
Peace out
Steve
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It compiles fine for me as well.
What are you using to compile it? If you're using a third party compiler (like jikes), you'll need to include in your CLASSPATH the rt.jar file located in the [JDK_HOME]\jre\lib folder.
[ March 24, 2003: Message edited by: Dirk Schreckmann ]
 
Adam Polak
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found the problem on my own people but thanks anyway!
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So, what was the problem?
 
Adam Polak
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ehm...kinda feel like a dumb ass about it...There was a typo while importing Tokenizer :roll:
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic