sapui5 - Not able to set property value from XML view for Formatted Text control -
my xml code throwing error
<formattedtext htmltext="<h1>welcome</h1>" id="ft"/>
with below way adding data controller working fine
<formattedtext id="ft"/> onafterrendering : function(){ this.getview().byid("ft").sethtmltext("<h1>welcome controller</h1>") }
can explain reason behind difference of working control.
when xml file parsed, certain characters have special (that is, high priority) meaning xml parser. when such characters encountered, interpreted part of xml definition , not part of other content might exist within xml document.
as xml parser encounters 1 of these high-priority characters (in case, less-than (<) character), interpreted start of new xml tag – irrespective of other meaning character might have within context of expression. known syntax collision.
you can read here
Comments
Post a Comment