File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other Application Frameworks and the fly likes Image doesnot get displayed in an Eclipse OSGi Project Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "Image doesnot get displayed in an Eclipse OSGi Project" Watch "Image doesnot get displayed in an Eclipse OSGi Project" New topic
Author

Image doesnot get displayed in an Eclipse OSGi Project

Rl Kumar
Greenhorn

Joined: Jun 28, 2009
Posts: 6
I have created an Eclipse OSGi project and in the code i am trying to a create a new ImageIcon using the following code

url =Myclass.class.getResource("/images/default.gif");
image = new ImageIcon("/images/default.gif");

I am trying to run the Eclipse plugin from the cmd prompt using the following cmd
%JAVA_HOME%\bin\java -jar org.eclipse.osgi_3.2.0.v20060601.jar

I have created an image folder with the image in the directory from where I am running the above cmd.

My application gets launched but the ImageIcon do not get displayed.

Can you please help me figure where I am goining wrong.

Thanks in Advance!
 
 
subject: Image doesnot get displayed in an Eclipse OSGi Project
 
Similar Threads
Image formats allowed
Executable Jar
Image inside jar file
Multiple questions
Having issue accessing images inside jar