public System.Xml.XmlElement GetExportXml(System.Xml.XmlDocument doc) { System.Xml.XmlElement xe = XmlTool.NewXmlNode(doc, "table"); for (int i = 0; i < Cells.Length; i++) { EditorCell cell = (EditorCell)_Cells[i]; if (cell != null && cell.CanExport) { xe.SetAttribute(cell.ExportColId, cell.Value); } } return(xe); }
public string GetExportXml() { System.Xml.XmlDocument doc = new System.Xml.XmlDocument(); System.Xml.XmlElement root = XmlTool.NewXmlNode(doc, doc, ExportName); for (int i = 0; i < Rows.Length; i++) { EditorRow row = _Rows[i]; if (row == null || !row.CanExport) { continue; } System.Xml.XmlElement xe = row.GetExportXml(doc); XmlTool.SetParentXmlNode(root, xe); } return(ExcelFunction.ConvertXmlToString(doc)); }