DevTreks.Data/EditHelpers/XmlIO.cs
/// <summary>
/// Append an element to the first child of the last hierachical nodes contained in basedoc
/// </summary>
/// <param name="newDocNode">node being appended to lastbaseNode</param>
/// <param name="lastBaseNode">node where new element is being appended</param>
/// <param name="baseDoc">document holding lastBaseNode</param>
Append an element to the first child of the last hierachical nodes contained in basedoc
Append an element to the first child of the last hierachical nodes contained in basedoc
public static void AppendNodeToLastDocNode(XmlElement newDocNode, bool isDeepClone, XmlNode lastBaseNode, ref XmlDocument baseDoc)
        {
            if (lastBaseNode.HasChildNodes == true)
            {
                AppendNodeToLastDocNode(newDocNode, isDeepClone, lastBaseNode.FirstChild, ref baseDoc);
            }
            else
            {
                XmlNode oNodeToInsert = baseDoc.ImportNode(newDocNode, isDeepClone);
                lastBaseNode.AppendChild(oNodeToInsert);
            }
        }
public static void AppendNodeToLastDocNode ( XmlElement newDocNode , bool isDeepClone , XmlNode lastBaseNode , ref XmlDocument baseDoc ) { if ( lastBaseNode . HasChildNodes == true ) { AppendNodeToLastDocNode ( newDocNode , isDeepClone , lastBaseNode . FirstChild , ref baseDoc ) ; } else { XmlNode oNodeToInsert = baseDoc . ImportNode ( newDocNode , isDeepClone ) ; lastBaseNode . AppendChild ( oNodeToInsert ) ; } }
Append an element to the first child of the last hierachical nodes contained in basedoc
Append an element to the first child of the last hierachical nodes contained in basedoc
newDocNode
XmlElement
node being appended to lastbaseNode
node being appended to lastbaseNode
isDeepClone
bool
lastBaseNode
XmlNode
node where new element is being appended
node where new element is being appended
XmlDocument
ref
baseDoc
document holding lastBaseNode
document holding lastBaseNode