1 Reply Latest reply on Sep 19, 2010 8:58 PM by Anitha Selvaraj

    Add components into Tooltip ?


      Hi all,


           I have a textinput, I can show tooltip when I mouse roll over. But how I can add some component into a Tooltip (example chart, image, ...) ?



        • 1. Re: Add components into Tooltip ?
          Anitha Selvaraj Level 2



          Create a custom tooltip component (i.e., an mxml file with chart, image, etc.,). And provide the custom component to the Label's tooltip as below:



              private function createCustomToolTip(event:ToolTipEvent):void {
                   var toolTip:CustomToolTip = new CustomToolTip();

                    toolTip.object = even.target.data;
                   event.toolTip = toolTip;


          <mx:Label text="sample text"  toolTip=" " data="{data}"  toolTipCreate="createCustomToolTip(event)" />


          Here CustomToolTip is the mxml component with components like chart, image, etc.,




          1 person found this helpful