Results 1 to 2 of 2

Thread: Flash 2004 question

  1. #1
    Join Date
    Sep 2005

    Flash 2004 question

    I have some questions about flash, I would be so much grateful If you could helped me with this:

    1. How can I change the color of a listbox component? I mean How can change that green color which appears when you select an Item?

    2. I've wrote an actionscript which runs whenever someone presses a key. I used keydown event handler for this action. But this action doesn't work for "Enter" key and "Esc" key? I think It's because, flash doesn't get my key, and flash player uses the pressed key. (as you know "Esc" in flashplayer means "Exit Fullscreen mode")

    Thank you for your help in advance...

  2. #2
    Join Date
    Sep 2005
    1 Give your list a name ("my_list") and then try this code :

    my_list.setStyle("backgroundColor", 0xEFF2F9);
    my_list.setStyle("rollOverColor", 0x7C9DC5);
    my_list.setStyle("selectionColor", 0xFFFFFF);
    my_list.setStyle("textRollOverColor", 0xFFFFFF);
    my_list.setStyle("textSelectedColor", 0x355575);

    Just change the hex values to any color you like.

    2 Make a buton and use this code :

    on (keyPress "<Escape>") {
    //your code here

    To work with the "enter" key just replace "Escape" with "Enter".

    Have fun !

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center

Recent Articles