Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Changing the Background Color of the Applet

807598Dec 5 2005 — edited Dec 5 2005
I am trying to change the ugly gray color of the background of my applet but if i use setBackground(Color.blue) the blue color flashes and disappears and if i use getContentPane().setBackground(Color.blue); the backgroud becomes gray again as soon as i add a component using getContentPane().add(ButtonBar) for example.

Can anyone propose a solution?

Thanks in advance.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 2 2006
Added on Dec 5 2005
1 comment
155 views