On 6/27/05, tony_lic <[EMAIL PROTECTED]> wrote:

[snip]

>           <mx:DataGridColumn  cellRenderer="tick_comp" />
[...]

> 
>    as you can see,in the second column i'm using the cellrenderer
> which calls a mxml component "tick_comp". my idea is that i want to
> use two different mxml component, based on the value of the node
> status, which comes from a xml file.

Instead of having two different cell renderers, you can have one cell
renderer that creates different objects with different properties
based on the value of the status property.

For example, you can have a cell renderer containing an image:

 class MyImageCellRenderer extends UIComponent {
   var image:Image;

   setValue(...):Void
   {
      if (status == "done")
        image.source = ...;
     else
       ...
   }
 }

Is that what you're looking for?  A way to dynamically change the
contents of a cell depending on the value of the node's status
property?


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to