views:

312

answers:

1

How do I make text selectable (so I can copy) in a DataGridColumn?

+3  A: 

Create a custom component with a selectable label and assign it to the itemRenderer property of the data grid column:

DGCRenderer.mxml

<mx:Label xmlns:mx="http://www.adobe.com/2006/mxml" selectable="true">
</mx:Label>

Main.mxml

<mx:DataGridColumn dataField="name" headerText="Name" itemRenderer="DGCRenderer"/>
Amarghosh
ok thanks, had hoped to avoid creating a custom itemRenderer.
Niels Bosma