This is the legacy 4D documentation web site. Documentations are progressively being moved to developer.4d.com |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D v20.6
DOM Get last child XML element
|
DOM Get last child XML element ( elementRef {; childElemName {; childElemValue}} ) -> Function result | ||||||||
Parameter | Type | Description | ||||||
elementRef | String |
![]() |
XML element reference | |||||
childElemName | String |
![]() |
Name of child element | |||||
childElemValue | String |
![]() |
Value of child element | |||||
Function result | String |
![]() |
XML element reference | |||||
The DOM Get last child XML element command returns an XML reference to the last “child” of the XML element passed as reference in elementRef. This reference may be used with the other XML parsing commands.
The optional childElemName and childElemValue parameters, when passed, receive respectively the name and value of the “child” element.
Recovery of the reference of the last XML element of the parent root. The XML structure (C:\\import.xml) is loaded into a BLOB beforehand:
C_BLOB(myBlobVar)
C_TEXT($ref_XML_Parent;$ref_XML_Child)
C_TEXT($childName;$childValue)
DOCUMENT TO BLOB("c:\\import.xml";myBlobVar)
$ref_XML_Parent:=DOM Parse XML variable(myBlobVar)
$ref_XML_Child:=DOM Get last child XML element($ref_XML_Parent;$childName;$childValue)
If the command has been executed correctly, the system variable OK is set to 1. Otherwise, it is set to 0.
Product: 4D
Theme: XML DOM
Number:
925
Created: 4D 2004.2
4D Language Reference ( 4D v20)
4D Language Reference ( 4D v20.1)
4D Language Reference ( 4D v20.2)
4D Language Reference ( 4D v20.3)
4D Language Reference ( 4D v20.4)
4D Language Reference ( 4D v20.5)
4D Language Reference ( 4D v20.6)