Changing the Data Grid selection color, rollover color in Flex

Hi All,

As data grid comes with default color settings, So sometime if we want to change the color according to application UI needs.  Then below example shows how to set the roll over color and selection color in a DataGrid control in Flex by setting the rollOverColor  and selectionColor styles.

<DataGrid id=”dataGrid”
dataProvider=”{arr}”
rollOverColor=”green”
selectionColor=”lime”

themeColor=”black”
width=”300″
rowCount=”8″>
<mx:columns>
DataGridColumn dataField=”c1″
headerText=”Column 1:” />
DataGridColumn dataField=”c2″
headerText=”Column 2:” />
</mx:columns>
</mx:DataGrid>

Hope this helps.


Thanks
R Vashi.

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 )

Google+ photo

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

Connecting to %s