简体   繁体   中英

Icons don't appear after build when opening on other computer

I was working with JFrame in Netbeans, Java. I've made some buttons and added icons to them. When I build my project and open .jar file on my computer, I see the icons, but if I open that file on other computer, those buttons are empty. Where should I put the icons, so I could see them on another computer after build?

它们应该在您的jar文件中,并作为资源加载。

Problem solved. What I had to do is to put those icons into my projects package folder, then select "Image within project" in button options and add them again.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM