Hello everybody,
I have a DataGrid like this and a Custom Component Icon (based on Image). I
have iconTypes like Folder, Document and so on and I have to match them to the
Embeded ImageFiles.
I cannot see any solution. Maybe you see a completely different way to do
this. It seems to be easy, but I don't know how to do this with embededded
Images.
Thank you.
<mx

ataGrid>
<mx:columns>
<mx

ataGridColumn width="21">
<mx:itemRenderer>
<mx:Component>
<com:Icon iconType="{data.iconType}" />
</mx:Component>
</mx:itemRenderer>
</mx

ataGridColumn>
<mx

ataGridColumn headerText="Name" dataField="name"/>
</mx:columns>
</mx

ataGrid>
<mx:Image xmlns:mx="http://www.adobe.com/2006/mxml">
<mx:Script>
<![CDATA[
[Bindable]
public var iconType:String;
[Embed(source="img/cl_core.Folder.png")]
public static const FolderIcon:Class;
]]>
</mx:Script>
</mx:Image>