mardi 13 janvier 2015

Setting the value of a boolean XMLElement



I'm having a problem when assigning a value to a Boolean check/tick box within InfoPath xml code. I've created text boxes using inner text values but this gives the error of an incorrect data type. How do you set up a standard check box to a value of true using XmlElement?


Here's the code I attempted to use:



XmlElement elShowResult = xDoc.CreateElement("my", "ShowResult", NamespaceManager.LookupNamespace("my"));
elShowResult.InnerText = "TRUE";
elNewTestResult.AppendChild(elShowResult);







0 commentaires:

Enregistrer un commentaire