How to add image to netbeans java project

I am doing a simple Java project on Netbeans. And I'm stuck, not knowing how to add my own image to the code. He kept throwing an IOException no matter where I put the image. It sounds funny, but it really made me stuck.

+5
source share
2 answers

If you run the program from netbeans, the root folder must match the root of the project folder. That is, the folder containing build.xml and manifest.mf.

If you put the image directly in this folder, and downloading it without any given path does not work, you will also look at your code and see if you can find any errors.

+5
source

html/xhtml. - projectname/build/web. html, "src".

+1

All Articles