ChildElementValueByName (QTP, TestComplete, VBScript)
Parent page: Service Functions – MSXMLDOM (QTP, TestComplete, VBScript)
Description
Returns text value of a child XML node.
Implementation
Public Function ChildElementValueByName(ByRef objXMLParent, ByVal sTagName) Dim objNode If objXMLParent is Nothing Then Set ChildElementValueByName = "" Exit Function End If Set objNode = objXMLParent.SelectSingleNode("./"&sTagName) If isNull(objNode) Or (objNode is Nothing) Then ChildElementValueByName = "" Else ChildElementValueByName = p_GetXMLElementText(objNode) End If End Function