Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Jarring Problem. Please Help !

 
K. Sushant
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have developed an application involving internal frames and database connection. The class files are kept in the rot directory while the images required as icons are placed in the 'images' folder inside the root directory.
But when I created a jar file of the application, the application wouldn't procced ahead of the main class.
Why is this so ?
Is the 'images' folder required in the jar or not ?
Please help !
Thank You
 
Sanjeev Kaushik
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes images can be put in the jar file. And it can be accessed like this
URL url = getClass().getResource("/images/abc.gif");
now this URL can be used to get the image.
Hope this helps you.
Sanjeev Kaushik
 
Willie Smits increased rainfall 25% in three years by planting trees. Tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!