AddElement(String,String,String) Method
- Last UpdatedNov 06, 2025
- 1 minute read
This override adds an element and its text to the specified parent node (by name) in the XML doc Searches for the first parentNodeName in the XML document starting at the root node
'Declaration
Public Overloads Function AddElement( _
ByVal parentNodeName As String, _
ByVal nodeName As String, _
ByVal nodeText As String _
) As XmlElement
'Usage
Dim instance As XMLBuilder
Dim parentNodeName As String
Dim nodeName As String
Dim nodeText As String
Dim value As XmlElement
value = instance.AddElement(parentNodeName, nodeName, nodeText)
public XmlElement AddElement(
string parentNodeName,
string nodeName,
string nodeText
)
Parameters
- parentNodeName
- The parent element's node name as a string to which the specified node and text must be added
- nodeName
- The name of the node to add as a string
- nodeText
- The text for this new node as a string
Return Value
Returns a reference to the newly added XmlElement