1 Reply Latest reply on Aug 27, 2012 3:11 AM by sravansss

    Item Renderer does not show data

    Zolotoj Level 3

      I am having a problem showing data in the grid using a custom renderer.

      My column definition looks like this:

      <s:GridColumn

                          dataField="df1"

                          editable="true"

                          headerText="Relationship">

                          <s:itemRenderer>

                              <fx:Component>

                                  <s:GridItemRenderer>

                                      <s:Label text="{XML(data).df1.toString()}"/>

                                  </s:GridItemRenderer>   

                              </fx:Component>

                          </s:itemRenderer>

                      </s:GridColumn>  

       

      I am adding a row into datagrid like this. Syntax is a bit simplified:

      var newRow:* = grid.newItemFactory.newInstance();

      newRow.df1 = "Test";

      grid.dataProvider.addItemAt(newRow, 0);

       

      I was expecting to see "Test" in my column right away, but no matter whta I do it's not showing it.

       

      Thanks for the help.