• 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:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Junilu Lacar
  • Liutauras Vilda
Sheriffs:
  • Paul Clapham
  • Jeanne Boyarsky
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
Bartenders:
  • Jesse Duncan
  • Frits Walraven
  • Mikalai Zaikin

Not able to save a java program

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey friends,

Can someone please help me with this problem -

I m trying to save a Java program in notepad in the directory C:\Program Files\Java\jdk1.6.0_20\bin\AddTwoInt.java. It gives me this message in a pop-up -



C:\Program Files\Java\jdk1.6.0_20\bin\AddTwoInt.java
You do not have permission to save in this location.
Contact administrator to obtain permission.

Would you like to Save it in the Documents folder instead?


I just don't understand where i myself is the administrator how cant it allow me to save a java program?

Please help me out with it. I really need your help friends!!!

 
Bartender
Posts: 11497
19
Android Google Web Toolkit Mac Eclipse IDE Ubuntu Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Saving your code in the bin folder is a very bad idea.
You should have a something like c:\MyCode and use that for your code.
Once you move on to IDEs you will notice they do the same thing. You will end up with something like c:\workspace\project1...c:\workspace\projectn
 
Bartender
Posts: 4109
72
Hibernate Fedora Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I m trying to save a Java program in notepad in the directory C:\Program Files\Java\jdk1.6.0_20\bin\AddTwoInt.java.


That really is not a good place to save Java files anyway

I just don't understand where i myself is the administrator how cant it allow me to save a java program?


Are you logged in as the administrator? Can you save any other type of file in that location?
 
Marshal
Posts: 75861
361
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
When you open your command prompt write

mkdir java

. . . or similar, and you can get to your new "java" folder by writing

cd java

 
It's just like a fortune cookie, but instead of a cookie, it's pie. And we'll call it ... tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic