M
Magne Ryholt
I have a typed dataset with a field (represented as an xml attribute) of
type float (xs:float).
The value is at some point float.NaN (Not a number).
I do: myDataSet.WriteXml(theNameOfTheXmlFile, XmlWriteMode.IgnoreSchema);
In the xml file, this is now represented as: MyNameSpacePrefix:MyFloat="NaN"
So far so good, but when I try to read this xml file into the dataset later,
by: myDataSet.ReadXml(theNameOfTheXmlFile, XmlReadMode.IgnoreSchema);
a System.FormatException (additional text: Input string was not in a correct
format) is thrown due to this "NaN".
Anyone knows if it is possible (and how) to read back a "NaN" from an xml
file and make it be represented as float.NaN ?
type float (xs:float).
The value is at some point float.NaN (Not a number).
I do: myDataSet.WriteXml(theNameOfTheXmlFile, XmlWriteMode.IgnoreSchema);
In the xml file, this is now represented as: MyNameSpacePrefix:MyFloat="NaN"
So far so good, but when I try to read this xml file into the dataset later,
by: myDataSet.ReadXml(theNameOfTheXmlFile, XmlReadMode.IgnoreSchema);
a System.FormatException (additional text: Input string was not in a correct
format) is thrown due to this "NaN".
Anyone knows if it is possible (and how) to read back a "NaN" from an xml
file and make it be represented as float.NaN ?