30-08-23 08:45 AM
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
31-08-23 07:45 AM
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