Change DataGrid alternating cell background with an itemRenderer

if you want to Change the DataGrid cell background with an itemRenderer, the solution is there:

http://butterfliesandbugs.wordpress.com/2007/07/11/using-an-itemrenderer-to-change-the-background-of-a-datagrid-cell/

If you want to get an alternating custom color, here a little hack:

g.beginFill(0xCC0033,0.02);

The second beginFill param is the alpha. By setting it low you get the alternating datagrid bg color and your custom item renderer bgcolor to blend, giving an alternating custom color background :)

It’s a hack but it works :)

Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s


Follow

Get every new post delivered to your Inbox.