Hello everyone,
I have been bangin my head on this for a few hours tonight. It appears the XMLReader is not supported with the Netduino. Everything I try keeps throwing a SystemNotSupported Exception.
What Xml is supported?
Is there any way to parse the following Xml file from an SD card? It's small enough.
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="ProjectName" value="TestProject" />
<add key="Debug" value="true" />
<add key="ConnectionType" value="Serial" />
<add key="ConnectionString" value="PortName=COM1;BaudRate=9600;Parity=None;Databits=8;TimeOut=10;Stopbits=One;" />
</appSettings>
</configuration>
XML Reader Whoas
Started by Bendage, Mar 28 2012 03:46 AM
3 replies to this topic
#1
Posted 28 March 2012 - 03:46 AM
#2
Posted 28 March 2012 - 02:25 PM
My understanding is it's not an issue of the size of the XML file, it's the size of the XMLReader object. It's just too big to fit in the space available.
I've taken to using JSON for all my config data instead of XML, as it's a lot smaller, and I've got a full parser you can grab here
I should mention that the code is written for the 4.2 Framework, so if you're not running the 4.2 firmware, that code won't compile for you.
I've taken to using JSON for all my config data instead of XML, as it's a lot smaller, and I've got a full parser you can grab here
I should mention that the code is written for the 4.2 Framework, so if you're not running the 4.2 firmware, that code won't compile for you.
- mohammad likes this
#3
Posted 28 March 2012 - 03:59 PM
Thank you for the reply. Ya that seems to be what I've read everyone is doing... just sucks that's all. Was hoping for some nice small footprint xml parsing class somebody frustrated like me threw together.
Thanks for the JSON parser. Guess I need to find a .Net C# JSON to XML converter
#4
Posted 28 March 2012 - 05:15 PM
You could read the XML file(s) using Regular Expressions. They are supported in the new firmware from what I've read but i have not tested it myself.
http://forums.netdui...3-all-editions/
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users