From 526600963197b324d4d74ecda411577f578a89cc Mon Sep 17 00:00:00 2001 From: Patrick Ritchie Date: Tue, 24 Oct 2023 20:16:24 -0400 Subject: [PATCH] Fixed issue with XML output of SensorConfiguration.Channels --- src/MTConnect.NET-XML/Devices/XmlSensorConfiguration.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/MTConnect.NET-XML/Devices/XmlSensorConfiguration.cs b/src/MTConnect.NET-XML/Devices/XmlSensorConfiguration.cs index 28c1d09f..40a881bb 100644 --- a/src/MTConnect.NET-XML/Devices/XmlSensorConfiguration.cs +++ b/src/MTConnect.NET-XML/Devices/XmlSensorConfiguration.cs @@ -92,10 +92,14 @@ public static void WriteXml(XmlWriter writer, ISensorConfiguration sensorConfigu // Write Channels if (!sensorConfiguration.Channels.IsNullOrEmpty()) { + writer.WriteStartElement("Channels"); + foreach (var channel in sensorConfiguration.Channels) { XmlChannel.WriteXml(writer, channel); } + + writer.WriteEndElement(); } writer.WriteEndElement();