I am new to java and want to find out the easiest way in java
on netbeans to set a picture on an "ok button" when the action is peformed?
any suggestions???
Printable View
I am new to java and want to find out the easiest way in java
on netbeans to set a picture on an "ok button" when the action is peformed?
any suggestions???
Easiest way? There's really one main way to do it (that I know of). Place the image in an ImageIcon, and then place the imageicon into the button using the setImageIcon(...) method. You will need to read and study the Sun Swing tutorials JButton section to learn how to do this best.
Good luck.
And on Suns' tutorial you can find the same example. At least study that example. You can find a lots of examples on the web too. :)