My Code:
var tl:String = "<p>Hello, <img paddingTop='10' paddingBottom='10' src='https://imgssl.constantcontact.com/letters/images/v8_your_image_100x10 0.gif' align='right'></img></p>";
htmlFlowReference.textFlow = TextConverter.importToFlow(tl, TextConverter.TEXT_FIELD_HTML_FORMAT);
Please suggest what i doing wrong....
This is a sample of the code I'm using.
External XML File:
<?xml version="1.0" encoding="utf-8"?>
<TextFlow xmlns="http://ns.adobe.com/textLayout/2008" whiteSpaceCollapse="preserve">
<div>
<p>
<span>To change password perform the following steps:</span>
<br/><br/>
<span>1. Click on the eSubmit Plus menu option on the main navigation bar.</span><br/>
<span>2. Select Preferences from the drop down list as shown in figure 3.</span><br/>
<span>3. Enter your old password, enter your new password and verify the new password in the text area as seen in figure 4.</span><br/>
<span>4. Click the Save button to save the new password.</span>
<br/>
<img width="494" height="285" source="images/help/account_01.png"/>
<br/>
<img width="397" height="269" source="images/help/account_02.png"/>
</p>
</div>
</TextFlow>
Other external XML file:
<?xml version="1.0" encoding="utf-8"?>
<TextFlow xmlns="http://ns.adobe.com/textLayout/2008" whiteSpaceCollapse="preserve" fontSize="11">
<div>
<p>To log into the system, please do the following:</p>
<p/>
<p><img width="510" height="325" source="images/help/login_01.png"/></p>
<p/>
<p>Once your logon is successful you will be taken to the logon screen.</p>
<p/>
<p><img width="475" height="293" source="images/help/login_02.png"/></p>
</div>
</TextFlow>
Flex Code:
init() fires on creationComplete().
[Bindable] private var helpSource:TextFlow;
private function init():void
{
helpSource = TextFlowUtil.importFromXML(helpIndexSource);
}
<fx:Declarations>
<fx:XML id="helpIndexSource" source="xml/helpIndex.xml"/>
</fx:Declarations>
<s:RichEditableText id="helpIndexDisplay" x="10" y="10" width="220" height="530" editable="false" textFlow="{helpSource}"/>
I confirmed the bug. But it's a Flex bug. Please file it on https://bugs.adobe.com/flex/
North America
Europe, Middle East and Africa
Asia Pacific