• 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

The ridiculous Problem

 
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all, I am facing problem, with packages and classpath...

1. How to set and remove classpath...
2. How to use package declaration in the java file...(give me one example)
3. How to import package in another java file...

i ve tried all these in many ways...
ever since i ve set the classpath... to the package/folder
whatever java file i m creating is getting duplicated with the extension .000, .001
like abc.java, as soon as i m saving it, it becomes abc.000, if i m again compiling it bocomes abc.001 like...
also i am unable to save that file.. and open
the error msg it displays
Access denied. ...

i ve to save my programs in to drive's root only, can not in any directory/folder/package ..
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


1. How to set and remove classpath...


Have a read of our FAQ about this. Hopefully that will help. Let us know if you are still stuck.


2. How to use package declaration in the java file...(give me one example)





3. How to import package in another java file...


...with the import keyword:
 
Soni Mitesh
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
@Paul

Thnx paul but the main concern here is the file extension is
getting changed, and getting corrupted...
What to do for that?
 
Sheriff
Posts: 11343
Mac Safari Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Soni Mitesh:
...whatever java file i m creating is getting duplicated with the extension .000, .001
like abc.java, as soon as i m saving it, it becomes abc.000, if i m again compiling it bocomes abc.001 like...
also i am unable to save that file.. and open
the error msg it displays
Access denied. ...

i ve to save my programs in to drive's root only, can not in any directory/folder/package ..


Weird... Are you using an IDE with its own compiler? Or are you using Sun's javac compiler? Also, what operating system are you running?
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic