That kinda depends on what you mean by the "last row of data". If you
mean the last visible row (Which is the last row rendered - the renderer
is only called for visible data) then you can try this...
package
{
import mx.collections.ArrayCollection;
import mx.controls.*;
import mx.controls.dataGridClasses.DataGridListData;
public class myRenderer extends Text
{
public function myRenderer()
{
super();
}
override public function set data(value:Object):void
{
super.data = value;
if(value != null)
{
text = value[DataGridListData(listData).dataField];
if(listData.rowIndex == (owner as DataGrid).rowCount -
1)
{
trace("Rendering the last row");
}
}
}
}
}
--- In [email protected], "Matthew" <fume...@...> wrote:
>
> Hi,
>
> I know the answer to this question before asking it but hopefully
someone has a found a way to do this.
>
> Is there a way to know (in my override of set data() method) whether
my item renderer is rendering the last row of data?
>
> thanks for any help on this one,
>
> matt
>