Change Color at Runtime in Forms6i

I have used Oracle 9i (9.2.0.1) and developer 6i on Windows XP machine.
I want to change colour , font of the text/display field at runtime.

Hello user506051
Or u can use:
SET_ITEM_PROPERTY
(item_name VARCHAR2,
property NUMBER,
value VARCHAR2);
property can be:
BACKGROUND_COLOR or FILL_PATTERN -> value e.g. 'RED' or 'BLUE'
FONT_NAME -->'ARIAL' or FONT_SIZE --> 12
FOREGROUND_COLOR -> value e.g. 'black' etc.
Best Regards,
Abdetu..

Similar Messages

  • Still can't change shape's color in runtime

    Hi , I've read many of the earlier posts in the subject , and everyone saying , that if I want to change a shape's color in runtime I should just after creating the shape , add the line:
    shape.setCapability(shapw.ENABLE_APPEARANCE_MODIFY);
    I've tried it with boxes , and cylinders , and it just doesn't work!!! it keeps throwing exceptions when I try to set a new appearance after the scene was loaded
    PLEASE HELP!!!

    I SOLVED THE PROBLEM!
    I've done some deeper digging in the post archives , and I found a reply of NathalieP that works -
    I need to do .setCapability , not only to the box itself , but to all the box's parts - TOP,BUTTOM.....
    THANKS NathalieP

  • Change item background color on runtime

    Hello
    i have a List control in my application. What do I have to do
    to change its items background color on runtime?
    Thanks

    You have to access the style of the object and then set the
    piece of the style you want to change. You need to set
    backgroundColor.
    myList.setStyle("backgroundColor", "#ABABAB");
    #ABABAB is grey, and you can put any hex color value there
    you like.
    Hope that helps.

  • How to change Text2D color at runtime...

    Hi,
    In fact I used Text3D and I was able to change color, text, font, style at runtime. I don't know if you guys have the same problem but Text3D doesn't render correctly (some letters are hidden by others) (i'm on a SGI Irix).
    So I decided to go back to Text2D but I can't find how to change the color, text, font and style at runtime.
    I've a Shape3D instance myShape = new Text2D(someParams);
    When I want to change it I tried myShape = new Text2D(otherParams);
    But nothing happened...
    I've tried detaching the shape, modify it, and re-add it to the graph, but it is still the same after adding it...
    If someone could tell me how I can do that it would be a great help.
    thank you
    Fred

    http://forum.java.sun.com/thread.jsp?forum=21&thread=356750

  • Changing Images at Runtime...it's sending me nuts (I'm a newbie, go easy)

    Hi all,
    I am trying change images at runtime and quite frankly it's driving me nuts. I'm pretty new to Java and don't understand some of the principles but I'm trying. I have this code below, that loads up a few images. I want to be able to change some/all of these images either on a timed even or on a button press, but all the things I've tried don't work. Can someone offer me some help....thanks in advance
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class bc extends JFrame implements ActionListener {
         public static void main(String[] args) {new bc();}
         bc() {
              //setUndecorated(true); // - this removed the titlebar!
                    setTitle("BC...");
              setSize(350,125);
              setResizable(false);
              setLocation(50,50);
              setDefaultCloseOperation(EXIT_ON_CLOSE);
              setBackground(new Color(0,0,0));
              getContentPane().setBackground(new Color(255,255,255));
              JPanel hours = new JPanel();
              hours.setLayout(new GridLayout(4,2));
              hours.add(hour14);
              hours.add(hour24);
              hours.add(hour13);
              hours.add(hour23);
              hours.add(hour12);
              hours.add(hour22);
              hours.add(hour11);
              hours.add(hour21);
              JPanel mins = new JPanel();
              mins.setLayout(new GridLayout(4,2));
              mins.add(min14);
              mins.add(min24);
              mins.add(min13);
              mins.add(min23);
              mins.add(min12);
              mins.add(min22);
              mins.add(min11);
              mins.add(min21);
              JPanel secs = new JPanel();
              secs.setLayout(new GridLayout(4,2));
              secs.add(sec14);
              secs.add(sec24);
              secs.add(sec13);
              secs.add(sec23);
              secs.add(sec12);
              secs.add(sec22);
              secs.add(sec11);
              secs.add(sec21);
              JPanel helptext = new JPanel();
              helptext.setLayout(new GridLayout(4,2));
              helptext.add(new JLabel("8"));
              helptext.add(new JLabel("4"));
              helptext.add(new JLabel("2"));
              helptext.add(new JLabel("1"));
    //add action listenters
              changeImg.addActionListener(this);
              JPanel cp = new JPanel();
              cp.setLayout(new GridLayout(1,6));
              cp.setBackground(new Color(255,255,255));
              cp.add(hours);
              cp.add(mins);
              cp.add(secs);
              cp.add(helptext);
              cp.add(changeImg);
              setContentPane(cp);
              setVisible(true);
         public void actionPerformed(ActionEvent ae) {
              hour11.PaintOff(1);
              //JOptionPane.showMessageDialog(this, "changed");
              repaint();
    JPanel hour11 = new PaintOff(0);
    JPanel hour12 = new PaintOff(0);
    JPanel hour13 = new PaintBlank();
    JPanel hour14 = new PaintBlank();
    JPanel hour21 = new PaintOff(0);
    JPanel hour22 = new PaintOff(0);
    JPanel hour23 = new PaintBlank();
    JPanel hour24 = new PaintBlank();
    JPanel min11 = new PaintOff(0);
    JPanel min12 = new PaintOff(0);
    JPanel min13 = new PaintOff(0);
    JPanel min14 = new PaintOff(0);
    JPanel min21 = new PaintOff(0);
    JPanel min22 = new PaintOff(0);
    JPanel min23 = new PaintOff(0);
    JPanel min24 = new PaintOff(0);
    JPanel sec11 = new PaintOff(0);
    JPanel sec12 = new PaintOff(0);
    JPanel sec13 = new PaintOff(0);
    JPanel sec14 = new PaintOff(0);
    JPanel sec21 = new PaintOff(0);
    JPanel sec22 = new PaintOff(0);
    JPanel sec23 = new PaintOff(0);
    JPanel sec24 = new PaintOff(0);
    JButton changeImg = new JButton("change");
    }///---------This is my PaintOff class ---------------\\\
    import javax.swing.*;
    import java.awt.*;
    import java.awt.Image.*;
    public class PaintOff extends JPanel {
    Toolkit tk = Toolkit.getDefaultToolkit();
    public Image imgOff = tk.getImage("off.jpg");
    public Image imgOn = tk.getImage("on.jpg");
    public Image paintMe = tk.getImage("off.jpg");
         PaintOff(int a) {
              if(a == 1) {
                   vOn();
              } else {
                   vOff();
         public void vOn() {
            paintMe = imgOn;
         //JOptionPane.showMessageDialog(new bc(), "shown");
         public void vOff() {
            paintMe = imgOff;
         public void paintComponent(Graphics g) {
              g.drawImage(paintMe,0,0,this);
    }PaintBlank class is not included here, it's basically just the same as PaintOff but only has one image inside.
    When I try and compile this code, I get
    C:\jdk1.4\bin\bclock>javac bc.java
    bc.java:79: cannot resolve symbol
    symbol : method PaintOff (int)
    location: class javax.swing.JPanel
    hour11.PaintOff(1);
    ^
    1 error
    I don't understand this either, I've tried replacing "PaintOff(1)" with "vOn()" but I get the same error. This is baffling to be, as I thought that the hour11 would have access to all the methods inside the PaintOff class?
    Anyway, thanks for any help you guys give me!
    Cheers
    //Chris.

    Hi!
    Your problem is that you've used a widening conversion to convert from PaintOff to a JPanel. JPanel has no such method, and so the compiler is complaining that it can't find it.
    e.g
    public class NoCompile{
         public static void main(String args[]){
              One one = new Two();
              one.methTwo();
    public class Two extends One{
         public Two(){}
         public void methTwo(){
            System.out.println("Executed 2");
    public class One{
         public One(){}
         public void meth1(){}
    } will give you the same sort of error message. To make the compiler happy, use a cast.
    Now this will compile and gives the right result.
    public class NoCompile{
         public static void main(String args[]){
              One one = new Two();
              ((Two)one).methTwo();
    }So in your case, you want to do
    ((PaintOff)hour11).vOn();
    Does that help?
    :) jen

  • S:TextArea How change color for some chars in text?

    I have s:TextArea and i need in runtime change color for some chars displayed in text.
    How i must to do this correctly?

    pcardinale wrote:
    Initially, a control has no caption.  It's not just that the caption string is empty and the caption not visible, but the caption object does not exist.
    I think this should probably be changed in future versions, because even if each control had a caption, it would still be a negligible small part of the VI. The current behavior made sense many years ago where HD and memory space was very precious. Not any more!
    This issue comes up often enough that it warrants addressing the root of the problem.
    It is hard to convince the casual that the caption does not exist if he can simply do a "show caption" at edit time and it will show in all glory, even with the default set to the current label. It is confusing!
    There is even an idea about this that seems worth supporting (also read the link in the discussion).
    What do you think?
    LabVIEW Champion . Do more with less code and in less time .

  • Changing Color of seekBar component

    hi,
    i m creating a video player, in which i m using control of
    play, pause, seekbar etc.
    i want to chnage the color of prograss of seekbar at runtime
    as user select different color from colorPicker component.
    and i know how to apply the color at runtime using colot
    transfor class.
    The problem is i m unable to refer the movieclip of seekbar
    which contain the shape of pregrass.
    and if entered the reference then it throug error.
    i m using AS3.0 version. so please help me to how can i refer
    the prograss shape inside of seekBar component to change the color
    at runtime.
    Thanks in Advance.

    Once you drag it to the stage, look for it in your library.
    When you open it from the library you can edit the appearance to be
    whatever you want.

  • Moving a rectangle or change color in "Run-Time "?

    First step, the objects of decoration you can modify its properties in "Run-Time "?
    Moving a rectangle or change color in "Run-Time "?
    I want to develop a mini SCADA application, where I have to do some animations usingsimple objects like Shapes.

    Yes, it is possible to modify decorations in runtime. An example is below.
    As you can see, you just need to get a reference to the front panel containing the decoraitions, and then use the Decos[] property to get an array of references to the decorations. These can be passed to a property node.
    Unfortunately, the decorations cannot be given a unique identifier, such as a label. So if you have multiple decorations, it can be tricky to modify the properties of a specific one. If you are only dealing with one shape, this won't be an issue. One roundabout way to pick out a particular decoration would be to search through the array references until you find the one with matching size and location on the front panel. Alternatively, you could use a disabled control, such as a boolean push button with no caption, and refer to that directly.
    Hope this helps.
    -Garrett

  • Change UIDefaults values runtime.

    Hi All,
    I want to change UIDefaults settings values at runtime on pressing the button event.
    setBackground() method works ok. but it changes only particular components color. i want to change the background of all the panels used in the application.
    Is it possible??
    Please help me.
    Sample code is as belove...
    import java.awt.BorderLayout;
    import java.awt.Color;
    import java.awt.event.ActionListener;
    import javax.swing.JButton;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    import javax.swing.JPanel;
    import javax.swing.UIDefaults;
    import javax.swing.UIManager;
    public class Test extends JFrame
         public static void main(String args[]) throws Exception
              UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
              UIDefaults defs = UIManager.getDefaults();
              defs.put("Panel.background",Color.BLUE);
              Test t = new Test();
              t.setVisible(true);
         public Test()
              setDefaultCloseOperation(EXIT_ON_CLOSE);
              setSize(400,200);
              final JPanel panel = new JPanel(new BorderLayout());
              panel.add(new JLabel("Amit"),BorderLayout.CENTER);
              JButton button = new JButton("Change color...");
              panel.setLayout(new BorderLayout());
              button.addActionListener(new ActionListener(){
                   public void actionPerformed(java.awt.event.ActionEvent e) {
                        UIDefaults defs = UIManager.getDefaults();
                        defs.put("Panel.background",Color.RED);          
                        /// no effect.. :(
                        // Some code to give proper effect ...
              panel.add(button,BorderLayout.SOUTH);
              getContentPane().add(panel);
    }Thanks in advance.
    Amit Chudasama
    Y! id : amit.chudasama

    Read the Swing tutorial on [url http://java.sun.com/docs/books/tutorial/uiswing/misc/plaf.html]How to Set the Look and Feel. I believe you would need to use the following after changing the defaults in order for them to be applied to existing components:
    SwingUtilities.updateComponentTreeUI(frame);

  • Email download changes color to blue and prints blue

    I recently purchased a Satellite Pro L300=EZ1523 and all is great except when I download attachment from email it turns the color to blue and also prints out in blue color.  This seems to come from Picasa3.  How can I fix this issue?  My documents print out the way they should.  Any help would be much appreciated.
    Thank you,  dml

    You just changing the color on runtime without saving it, next time you launch the form it will read the default properties set. Follow the steps in the below post written by jmcilhinney 
    to create the settings (remember to create unique  and easy to refer names):
    http://www.vbforums.com/showthread.php?681367-RESOLVED-Save-Load-TextBox-BackColor
    and then from your code you can set the new colors as following:
    Dim slateBlue As Color = Color.FromName("AliceBlue")
    My.MySettings.Default.BackColor = slateBlue
    Like this everytime you change the color will be saved in the temp folder of the user machine and will be retreived on each launch.
    You will be able to see the new settings created in your app.config as below:
    <userSettings>
    <WindowsApplication2.My.MySettings>
    <setting name="BackColor" serializeAs="String">
    <value>255, 192, 192</value>
    </setting>
    </WindowsApplication2.My.MySettings>
    </userSettings>
    Just a note that changing the above value in the code will not reflect in app.config file, rather since it is a user scoped variable it will be saved in C:\Users\{YourUsername}\AppData\Local\  under you application dir in the file user.config as
    below:
    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
    <userSettings>
    <WindowsApplication2.My.MySettings>
    <setting name="BackColor" serializeAs="String">
    <value>AliceBlue</value>
    </setting>
    </WindowsApplication2.My.MySettings>
    </userSettings>
    </configuration>
    Fouad Roumieh

  • Why do I get a program error when changing colors?

    I get a 'Could not complete your request because of a program error' when I try to change colors on both the forground/background palette or from the color picker palette.  Is there a patch for this?
    I am using Photoshop CS6 version 13.0.1.x64

    Hi. Because this forum is for beginners trying to learn the basics of Photoshop, I'm moving your question to the Photoshop General Discussion forum.

  • Images Change Colors between monitors while the UI stays the same

    Hey! Im having an issue where photoshop changes the colors when I move the window between my monitors, seen here: http://sta.sh/04y5s60vf3j This isnt due to the monitors themselves being different, it actually changes after a few seconds of moving it inbetween the monitors. The left one has been callibrated with a spyder 3 elite which I no longer have access to. I applied the file with windows color management instead of the spyder utility. The second one is new, and it is not callibrated by anything, but instead was done by hand with the built in brightness/contrast/custom RGB settings. Both of them are very close to eachother, enough so for my tastes. but when photoshop changes what the image looks like, it's causing problems. Interestingly enough, when I disable callibration for the monitor on the left, the image does not change colors between monitors, but instead always appears as it does on the right. but then they don't match up and the whole screen looked washed out because it's uncallibrated, so that doesnt do me any good. Another interesting thing to point out, is when this image is saved as a .JPG, and viewed with firefox the image appears exactly like the monitor on the LEFT (which is my main monitor) despite the left monitor being the one that is force changed. does anyone have any suggestions? It also appears that windows photoviewer is behaving the same way, though firefox does not. Meaning when I open an image in all 3 on the left monitor, they look the same, but when opened on the right monitor, windows photo viewer and photoshop both display the image as brighter and redder than firefox does. This is frustrating, because it seems photoshop is changing the image with my callibration on my left monitor to match what it looks like on the web, which it does. but it doesn't do this for the right monitor, or when the left is uncallibrated. Another issue I can see with this is even if the UI is the same shade of gray, the images are different between the monitors because of this change. Does anyone have any suggestions?
    - BD

    Alright! So I reread through all this, poked at some things on the internet, and I'm going to attempt to summarize what would be a good solution for all this (And it seems, it still won't be perfect, but to get myself into the best environment I can for not messing with images for an hour trying to make them look nice before I post them to the web. I painted something yesterday on the cintiq, popped it over to my laptop screen and it just looked washed out and terrible.)
    1. Get a X-rite EODIS3 i1 Display Pro, Callibrate laptop and cintiq. I do have the money to drop on something like this, especially if it's a time saver.
         Things I'm not sure about:
              a. There was a ton of complaints about the software not working when I checked reviews, but also a ton that said everything was great. most of them were mac users though.
              b. I'm not sure if problems would still be posed, even while calibrated, by me having a wide gamut monitor.
              c. I'm a terrible excuse for a human being and I think the colors showing up brighter on the wide gamut screen is pretty (I should just make my images this bright on a normal screen and there won't be any issues. >.>)
    2. Set Firefox to color manage (easy enough)
    3. Change my photoshop working space to sRGB (since they'll have been calibrated at this point)
    3. Accept the fact that most of the people who look at my work will be doing so on a monitor that is almost certainly uncalibrated, and I can't control what they will see on my screen, but I CAN control if the colors are -actually- what I want them to be on any properly calibrated device. which is probably the best way to go anyways.
    4. Make paintings, have fun.
    Now, you two have been going on about all sorts of interesting things in here, and it seems that calibration issue run much much deeper than I ever thought. Do either of you have recommendations for how I should tweak this list of things to do or other things I can/ should do? I'm not currently a working professional, but if I have anything to say about it, I will be within a few years (I'm going to school for illustration and studying concept design on my own time) so it'd be useful for me to get into good habits now.
    - Brendavid

  • Can anyone tell me why a picture would change color when I try to download/upload it?  It is the exact same picture- chosen the same way and when it goes to any other program it changes the color (I've tried canvas on demand and mpixpro.  I've also tried

    Can anyone tell me why this picture changes color when I try to download/upload it?  It is the exact same picture I have taken from the same location.  The image on the left is via preview and the image on the right is what is shows like when I try to download it.  I have emailed it to myself and it shows fine on the computer and in CS4, but when I look at the download via my phone or on another computer it shows the wonky color on the right.  I have checked the color space shows RGB/8 bit.  Any ideas why or how to fix it?  It isn't with any one specific session.... and I've tried it on both my desktop and my laptop- saved image to an external hard drive and to drop box.  I've tried sending the image to canvas on demand, my email, mpxipro, POST editing- all the same result.  Please HELP!!  What am I doing wrong?

    Most of the time you see something like that. The image in question has a color profile other then sRGB. Some image viewers/displayers are color managed and others are not.  So the image do not look the same in all of the applications you use. So colors seem to change.
    Try converting it to sRGB color and see if then looks the same all around. Also I think PC and Mac displays are set to different gamma something like 1.8 and 2.2
    Though I'm colorblind I even see color variations.

  • How to change color of selected label from list of labels?

    My Problem is that I have a list of labels. RowHeaderRenderer is a row header renderer for Jtable which is rendering list items and (labels).getListTableHeader() is a method to get the list. When we click on the label this code is executed:
    getListTableHeader().addMouseListener(new MouseAdapter()
    public void mouseReleased(MouseEvent e)
    if (e.getClickCount() >= 1)
    int index = getListTableHeader().locationToIndex(e.getPoint());
    try
    if (((ae_AlertEventInfo)theAlerts.values().toArray()[index]).ackRequiredFlag)
    AcknowledgeEvent ackEvent = new AcknowledgeEvent(
    this, (ae_AlertEventInfo)theAlerts.values().toArray()[index]);
    fireAcknowledgeEvent(ackEvent);
    ((HeaderListModel)listModel).setElementAt(ACK, index);
    catch(Exception ex) {;}
    Upon mouse click color of the label should be changed. For some period of time ie. Upto completion of fireAcknowledgeEvent(ackEvent);
    This statement is calling this method:
    public void handleAcknowledgeEvent(final AcknowledgeEvent event)
    boolean ackOk = false;
    int seqId = ((ae_AlertEventInfo)event.getAlertInfo()).sequenceId;
    if (((ae_AlertEventInfo)event.getAlertInfo()).ackRequiredFlag)
    try
    // perform call to inform server about acknowledgement.
    ackOk = serviceAdapter.acknowledge(seqId,
    theLogicalPosition, theUserName);
    catch(AdapterException aex)
    Log.error(getClass(), "handleAcknowledgeEvent()",
    "Error while calling serviceAdapter.acknowledge()", aex);
    ExceptionHandler.handleException(aex);
    else
    // Acknowledge not required...
    ackOk = true;
    //theQueue.buttonAcknowledge.setEnabled(false);
    final AlertEventQueue myQueue = theQueue;
    if (ackOk)
    Object popupObj = null;
    synchronized (mutex)
    if( hasBeenDismissed ) { return; }
    // mark alert event as acknowledged (simply reset ack req flag)
    ae_AlertEventInfo info;
    Iterator i = theAlerts.values().iterator();
    while (i.hasNext())
    info = (ae_AlertEventInfo) i.next();
    if (info.sequenceId == seqId)
    // even if ack wasn't required, doesn't hurt to set it
    // to false again. But it is important to prevent the
    // audible from playing again.
    info.ackRequiredFlag = false;
    info.alreadyPlayed = true;
    // internally uses the vector index so
    // process the queue acknowledge update within
    // the synchronize block.
    final ae_AlertEventInfo myAlertEventInfo = event.getAlertInfo();
    SwingUtilities.invokeLater(new Runnable()
    public void run()
    myQueue.acknowledge(myAlertEventInfo);
    myQueue.updateAcknowledgeButtonState();
    // here we should stop playing sound
    // if it is playing for this alert.
    int seqId1;
    if (theTonePlayer != null)
    seqId1 = theTonePlayer.getSequenceId();
    if (seqId1 == seqId)
    if (! theTonePlayer.isStopped())
    theTonePlayer.stopPlaying();
    theTonePlayer = null;
    // get reference to popup to be dismissed...
    // The dismiss must take place outside of
    // the mutex... otherwise threads potentially
    // hang (user hits "ok" and is waiting for the
    // mutex which is currently held by processing
    // for a "move to summary" transition message.
    // if the "dismiss" call in the transition
    // message were done within the mutex, it might
    // hang on the dispose method because the popup
    // is waiting for the mutex...
    // So call popup.dismiss() outside the mutex
    // in all cases.
    if(event.getSource() instanceof AlertEventPopup)
    popupObj = (AlertEventPopup)event.getSource();
    else
    popupObj = thePopups.get(event.getAlertInfo());
    thePopups.remove(event.getAlertInfo());
    SwingUtilities.invokeLater(new Runnable()
    public void run()
    // search vector elements to determine icon color in main frame
    String color = getColor();
    fireUpdateEvent(new UpdateEvent(this, blinking, color));
    // Call dismiss outside of the mutex.
    if (popupObj !=null)
    if(popupObj instanceof AlertEventPopup)
    ((AlertEventPopup)popupObj).setModal(false);
    ((AlertEventPopup)popupObj).setVisible(false); // xyzzy
    ((AlertEventPopup)popupObj).dismiss();
    else
    // update feedback... ack failed
    SwingUtilities.invokeLater(new Runnable()
    public void run()
    myQueue.setInformationMessage("Acknowledge failed to reach server... try again");
    return;
    Code for RowHeaderRenderer is:
    class RowHeaderRenderer extends JLabel implements ListCellRenderer
    JTable theTable = null;
    ImageIcon image = null;
    RowHeaderRenderer(JTable table)
    image = new ImageIcon(AlertEventQueue.class.getResource("images" + "/" + "alert.gif"));
    theTable = table;
    JTableHeader header = table.getTableHeader();
    setOpaque(true);
    setHorizontalAlignment(LEFT);
    setForeground(header.getForeground());
    setBackground(header.getBackground());
    setFont(header.getFont());
    public Component getListCellRendererComponent( JList list, Object value,
    int index, boolean isSelected, boolean cellHasFocus)
    int level = 0;
    try
    level = Integer.parseInt(value.toString());
    catch(Exception e)
    level = 0;
    if (((ae_AlertEventInfo)theAlerts.values().toArray()[index]).ackRequiredFlag)
    setBorder(UIManager.getBorder("TableHeader.cellBorder"));
    this.setHorizontalAlignment(JLabel.CENTER);
    this.setVerticalAlignment(JLabel.CENTER);
    setIcon(image);
    else
    setBorder(BorderFactory.createLineBorder(Color.gray));
    setText("");
    setIcon(null);
    return this;
    I tried but when i am clicking a particular label, the color of all labels in the List is being changed. So can you please assist me in changing color of only the label that is selected and the color must disappear after completion of Upto completion of fireAcknowledgeEvent(ackEvent);

    im a bit confused with the post so hopefully this will help you, if not then let me know.
    I think the problem is that in your renderer your saying
    setBackground(header.getBackground());which is setting the backgound of the renderer rather than the selected item, please see an example below, I created a very simple program where it adds JLabels to a list and the renderer changes the colour of the selected item, please note the isSelected boolean.
    Object "value" is the currentObject its rendering, obviously you may need to test if its a JLabel before casting it but for this example I kept it simple.
    populating the list
    public void populateList(){
            DefaultListModel model = new DefaultListModel();
            for (int i=0;i<10;i++){
                JLabel newLabel = new JLabel(String.valueOf(i));
                newLabel.setOpaque(true);
                model.addElement(newLabel);           
            this.jListExample.setModel(model);
            this.jListExample.setCellRenderer(new RowHeaderRenderer());
        }the renderer
    class RowHeaderRenderer extends JLabel implements ListCellRenderer
        JTable theTable = null;
        public Component getListCellRendererComponent(JList list, Object value,
                                                      int index, boolean isSelected, boolean cellHasFocus){
            JLabel aLabel = (JLabel)value;
            if (isSelected){
                aLabel.setBackground(Color.RED);
            }else{
                aLabel.setBackground(Color.GRAY);
            return aLabel;       
    }

  • Changing color without modifying existing items.. problem!

    Hello,
    I'm reletively new to flash, and am trying to modify a template and am running into a problem and I don't seem to know why Flash is acting so strange.
    I am going into a movie clip to edit the color of an item, and when I do so with a tint, it overrides any additional effects such as light, and text. The color appears almost as if it were just slapped on top of everything.
    When I edit the color in advanced mode, it is really a hit-or-miss to get the correct color, and will only modify when changing the offset RGB.
    And also when doing this, the text gradually changes color, for example: there are 4 items in total that I want to edit the color of. Each item is a different colored box with text on the front (for a main Navigation of the website). --- The first item, the text will stay white. Gradually through the second and third items it starts to change, and by the fourth / last item, the text is completely blue.
    Is it possible for a portion of text to be connected somehow to an object within the animation in a movieclip? If so, is it possible to go inside and edit this? -the shape, animation, and text?
    Is there an easier way to change the color of an item inside a movie clip? I can supply additional information if needed.. files etc.
    Am I doing something wrong / completely missing something?
    Thank you very much in advance for any help and/or advice!
    New Flasher,
    Lisa

    go one level deeper than the movieclip so you're editing the shape.

Maybe you are looking for