Click here to Skip to main content
15,664,619 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I'm using eclipse witht the jwindows addon thingy that lets me have a gui

this is my code im using



public Skin_Stealer_Pro() throws IOException {}

the weird thing about this is, I can run is, by right clicking and run as java application and it works the icon is on the window, but when I export the file onto my desktop, and then try to run it, the window dose not open, but i look in my windows task manager and I see it is running, so its running but its not running, I was wondering if anyone can help me fix this problem?
Fredrik Bornander 29-Jul-13 6:56am    
When you say "export the file onto my desktop", what do you mean?
Are you moving the .jar file to your desktop or are you doing something else?
[no name] 29-Jul-13 6:58am    
I go into eclipse and click export and then select the export destination to the desktop and it exports the jat file to the desktop
Fredrik Bornander 29-Jul-13 7:31am    
Then add a try-catch around the line(s) you think fail and log the exception message and stack trace.
TorstenH. 30-Jul-13 2:51am    

There is an exception popping in your code. That's why the app is running but not visible.
[no name] 30-Jul-13 2:53am    
exception popping? whats that?

1 solution

you have to make sure the Icon is available. That's not about the code, it's more about you organizing the resources.

Please make a folder "resources" aside of the folder "src". That is common sense.
In "resources" you'll create a folder "icons" and put the icon in there. Then reference that path and get the icon:

String path = ResourcesLoader.class.getResource("/resource/icons/icon.png").toString();

Should do the trick (depending on what type of project you run)

You can add more in the resource folder - like a folder "properties" with some property files in there.

make sure you deploy the icon with the app - mark the icon / the complete resources to become a part of the deployment.
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900