• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

still having trouble

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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 ]
 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

[ May 28, 2002: Message edited by: Robert Ziel ]
 
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It's that dang "Razz" Graemlin again. Always that dang "Razz" ...
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
David,
Are you running Windows?
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I can duplicate your error message when I try to compile and run this:

Is this what you were attempting to do?
 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
 
reply
    Bookmark Topic Watch Topic
  • New Topic