Application to show Image in UITextField
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"
initialize="initApp()">
<mx:Script>
<![CDATA[
import mx.core.UIComponent;
import mx.core.UITextField;
private var test:String = "<p>Who is the founders of google." + "<img src='http://blogs.citypages.com/gop/google.jpg' width='100' height='100'></p>" +
"<p></P>";
private var uitext:UITextField;
private var uicomp:UIComponent;
/* */
private function initApp():void
{
uitext = new UITextField();
uitext.width = 600;
uitext.height = 600;
uitext.multiline = true;
uitext.wordWrap = true;
uitext.autoSize = TextFieldAutoSize.LEFT;
uicomp = new UIComponent();
uicomp .addChild(uitext);
this.addChild(uitext);
uitext.htmlText = test;
}
]]>
</mx:Script>
</mx:Application>
nice article, i was wandering about for many days in understanding this :((
ReplyDelete