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

still having trouble

David Malott
Greenhorn

Joined: May 27, 2002
Posts: 6
When I try to run HelloWorld by typing "java java.HelloWorld" I get the following message.
Exception in thread "main" Java.Lang.SecurityException rohibited package name:java
at java.lang.ClassLoader.defineClass
<ClassLoader.java:246>
at java.security.secureClassLoader.defineClass
<SecureClassLoader.java:123>
this is only two of the 11 lines like this. If it's necessary to see them all, I can write them all out. I'm hoping someone can help me.
thanks
[ May 28, 2002: Message edited by: David Malott ]
[ May 28, 2002: Message edited by: David Malott ]
Robert Ziel
Greenhorn

Joined: Apr 22, 2002
Posts: 28

[ May 28, 2002: Message edited by: Robert Ziel ]
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
It's that dang "Razz" Graemlin again. Always that dang "Razz" ...


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
David,
Are you running Windows?
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
Try this:
1. Make a directory called "temp" somewhere
2. In this directory create and edit a file called "HelloWorld.java" with these contents:

3. From the command line, from the "temp" directory you've created, compile the file like this:
javac HelloWorld.java
4. From the command line, from the "temp" directory you've created, attempt to run the file like this:
java -classpath . HelloWorld
Any success?
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
I can duplicate your error message when I try to compile and run this:

Is this what you were attempting to do?
Onkar Shendge
Greenhorn

Joined: May 29, 2002
Posts: 11
I think here problem is that you are trying use package which is used by java for its own classes.
Try using some other package name


- Onkar
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: still having trouble