hi
i want to display the byte array value which is taken from backend
as image in spark image control in flex 4.5.
here is my code
public function getImage(bytes:ByteArray,context:LoaderContext =
null):void
{
var loader:Loader = new Loader();
loader.loadBytes(bytes,context);
loader.contentLoaderInfo.addEventListener(Event.COMPLETE,
loaderCompleteHandler);
}
private function loaderCompleteHandler(evt:Event):void {
var t:LoaderInfo = evt.currentTarget as LoaderInfo;
// display the jpeg in an Image component
patientInfo.img.source = t.content;
}
but it throws some error.
could you help me to resolve this issue!
--
You received this message because you are subscribed to the Google Groups "Flex
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/flex_india?hl=en.