Java - Not Able To Change Panel Color

Status
This thread has been Locked and is not open to further replies. Please start a New Thread if you're having a similar issue. View our Welcome Guide to learn how to use this site.

Prashanti

Thread Starter
Joined
Apr 24, 2006
Messages
67
Hi!!:)

There is a java prg in which there are two panels within a panel. When I try to change the color of these panels it does not reflect the changes on screen when the prg is run.:(

I used the following code for changing background color:

Code:
p1.setBackground(new color(192,255,192));
Any ideas on why it doesn't respond???:confused:

Any help would be appreciated!!!:)
 
Joined
Jul 29, 2004
Messages
6,650
Hi Prashanti,

Without your coding, it's pratically impossible to help you solving the display problem.
BTW, refreshing GUI's can only be operated during an event treatment or by a separate thread.
 
Status
This thread has been Locked and is not open to further replies. Please start a New Thread if you're having a similar issue. View our Welcome Guide to learn how to use this site.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 807,865 other people just like you!

Latest posts

Staff online

Top