This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes HELP - JDialogs! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "HELP - JDialogs!" Watch "HELP - JDialogs!" New topic

HELP - JDialogs!

Dave Donohoe
Ranch Hand

Joined: May 16, 2000
Posts: 73
Hi all - hope someone can help.
I Have a few JDialog boxes in my app & I cant set the icon on the Title Bar of the JDialog. I tried using this.setImageIcon(Image myImage) however I could not create an Image from the gif that I want to use.
Martin webster

Joined: Jun 20, 2001
Posts: 20
If you want to display a gif, then the easiest approach to take is to create an ImageIcon, whose constructor takes the name of the image....
dlg.setImageIcon(new ImageIcon("image1.gif"));

I agree. Here's the link:
subject: HELP - JDialogs!