I have created a ItemRenderer that displays some text based on values in the
XML data. Everything works as expected, but I want to display a image based
on the value in the XML data. The image source attribute =
"{XML(data)[EMAIL PROTECTED]" which returns a value = "addNew", but does not
load the
image defined in the class. The full code is below.
<mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml"
horizontalAlign="center" width="86" height="80">
<mx:Spacer height="1"/>
<mx:VBox width="100%" height="100%" borderStyle="solid"
borderThickness="3" backgroundColor="#a4b7ac" borderColor="#99aea3"
xmlns:head="layout.*" xmlns:components="components.*"
verticalAlign="top" cornerRadius="11">
<!--mx:Label text="[EMAIL PROTECTED]"
id="testme" textAlign="center"/-->
<mx:Label text="{XML(data)[EMAIL PROTECTED]"
id="testmets" textAlign="center" fontWeight="bold"/>
<mx:Label text="{XML(data)[EMAIL PROTECTED]"
id="testme" textAlign="center"/>
<mx:Image id="myLogo"
source="{XML(data)[EMAIL PROTECTED]"/>
</mx:VBox>
<mx:Script>
<![CDATA[
[Bindable]
[Embed(source="../assets/add.png")]
public var addNew:Class;
]]>
</mx:Script>
</mx:VBox>
Jerry DuVal
Pace Systems Group, Inc.
800.624.5999
www.Pace2020.com