Wednesday 15 February 2012

Inserting an image as a label in java -



Inserting an image as a label in java -

label_007= new jlabel("my label");

in lieu of above label, my label want insert image in same position. how can that? novice in java. please help

imageicon icon = new imageicon('image.png'); jlabel image = new jlabel(); image.seticon(icon);

the above code should work.

make image icon image file make jlabel then set jlabel's icon

java image label

No comments:

Post a Comment