• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Jar question

 
Rus Corina
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello. I have a question. I currently have a project that contains some buttons, to which i added some icons. The problem appears when i make a jar out of my project. The jar file does not take the icons. Does anyonje know what should I do in order to have the icons in the jar?
(I saved the icons in the folder of my project)
 
Wouter Oet
Saloon Keeper
Posts: 2700
IntelliJ IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you look at the Java tutorials Jar section?
 
Rus Corina
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I know this will sount very stupid, but, here it goes: yes, i've seen it, but i have absolutely no idea where to run this command:
jar cvf TicTacToe.jar TicTacToe.class audio images
or any other commands like this. So if you could help me, i would be really grateful. I only know how to make a jar in netbeans or eclipse.
 
Wouter Oet
Saloon Keeper
Posts: 2700
IntelliJ IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
On windows: press windowskey + r, type cmd, ok. Now a black screen will open. This is a console. With the command "cd <dirname>" you can go into a directory, with cd .. you can move up a directory. With the command "dir" you can view the directory content.

Now browse to your project location and then you can use the jar command. If you get the notification that the jar command is unknown then you'll need to add the locationWhereYouInstalledJava/bin to your PATH environment variable.
 
Rus Corina
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Wouter Oet
Thank you very much
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic