cancel
Showing results for 
Search instead for 
Did you mean: 

Collection (with datatypes collection) to XML

StephanieStrydo
Level 5

Hi, I need an action to convert a Collection (with datatypes collection) to XML. It seems simple to convert a simple collection with basic datatypes to XML, but becomes more complicated when you need children nodes in your XML. Just checking if anybody has working code for this, before I try to code a stage myself. Eventually I want to send the XML to MQ via a Webservice. Thank you



------------------------------
Stephanie Strydom
------------------------------
1 REPLY 1

Hi, Stephanie,

I tested with this code

XML = "";
using (StringWriter sw = new StringWriter()) {
    Input.WriteXml(sw);
    XML = sw.ToString();
}

and I got nested collection in XML as well. Could you be more specific about your requirements?

Thanks.

Regards

Zdenek



------------------------------
Zdeněk Kabátek
Head of Professional Services
NEOOPS
http://www.neoops.com/
Europe/Prague
------------------------------