Win a copy of OCP Java SE 8 Programmer II Exam Study Guide this week in the OCP forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How to use a jar file reference to normal java application  RSS feed

 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I'm working with swings, using command prompt for running the application. I have use use a third party tool for the look and feel which is present in a jar file. Can any one help me out in working with this. I have to get the reference of a class inside the jar file in to my swings application.
 
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maybe I misunderstood you but the only thing you have to do is to put that jar file into the classpath and then you can use the JAR's visible classes from your code as any other class.
 
Ranch Hand
Posts: 144
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Miklos Szeles wrote:Maybe I misunderstood you but the only thing you have to do is to put that jar file into the classpath and then you can use the JAR's visible classes from your code as any other class.


This. Add it to your classpath at run-time and to your build path during development time and you should be fine.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!