Hi all,
I’m trying to use Richtext controls in
browser enabled forms deployed to SharePoint however I am experiencing several
problems. Firstly having several rich text controls on one view makes the form
navigation slow and cumbersome when it’s used in a browser in InfoPath its
fine.
Also I’m trying to use some as a indicator
where a value set in a drop down control displays a certain icon depending on
its value in a rich text control. Much like a KPI indicator again this works
fine in InfoPath but in the browser form it responds slowly. I am using the
following code to set the icon however in the browser form the icons don't change for some time.
<code>
public void ControlChangedSetIcon(String
sNodeValue, String sControl)
{
XPathNavigator
rtfNav = xNavigator.SelectSingleNode(sControl, NamespaceManager);
string
nValue = xNavigator.SelectSingleNode(sNodeValue, NamespaceManager).Value;
if
(rtfNav == null || nValue ==null)
return;
switch
(nValue)
{
case
"1":
rtfNav.InnerXml = "<img
xmlns=\"http://www.w3.org/1999/xhtml\" src=\"http://domain/_layouts/images/KPINormal-1.GIF"
+ "\"/>";
break;
case
"2":
rtfNav.InnerXml = "<img xmlns=\"http://www.w3.org/1999/xhtml\" src=\"http://domain/_layouts/images/KPINormal-0.GIF" + "\"/>";
break;
case
"3":
rtfNav.InnerXml = "<img
xmlns=\"http://www.w3.org/1999/xhtml\" src=\"http://domain/_layouts/images/ewr236m.gif"
+ "\"/>";
break;
default:
rtfNav.InnerXml = "<img
xmlns=\"http://www.w3.org/1999/xhtml\" src=\"http://domain/_layouts/images/KPINormal-2.GIF"
+ "\"/>";
break;
}
}
</code>
Can anyone please advise?