View images in Swing

Dear friends...

I have a textbox where i am writing the complete path of an image to show an image in the right side of the window...

What should i do so that the system take the path from the input textbox and display the image file in the right side of the window?....

Please help me out..

Thank you

[banghead]

[357 byte] By [Java-Manoja] at [2007-11-26 22:40:46]
# 1
Use "new JLabel(new ImageIcon(filename));"
itchyscratchya at 2007-7-10 11:54:53 > top of Java-index,Desktop,Core GUI APIs...
# 2
U could make a JPanel and use paintComponent to draw the image on to the Jpanel.
S1lv3ra at 2007-7-10 11:54:53 > top of Java-index,Desktop,Core GUI APIs...
# 3
> U could make a JPanel and use paintComponent to draw> the image on to the Jpanel.Yes, but why draw the image 'manually' if you can use a JLabel?-Puce
Pucea at 2007-7-10 11:54:53 > top of Java-index,Desktop,Core GUI APIs...