1 Reply Latest reply on Mar 25, 2011 10:45 AM by Codeflayer

    Show icon in button

    jfb00 Level 3

      Hi All,

      I have a button using label and icon like:

      <mx:Button id="edit_btn" label="EDIT" icon="@Embed('assets/icons/edit.png')"  />


      I have an init function at the time of upload my form, I check for a condition and I can hide or show my edit button using visible property like:

      edit_btn.visible = true;  //or false


      If I use this property my icon doesn't show in my form.

      Any ideas?




        • 1. Re: Show icon in button
          Codeflayer Level 1

          Maybe try something like this:


                      private var editIcon:Class;
              <mx:Button id="edit_btn" label="EDIT" icon="{editIcon}" />