Vidíte historickú verziu tejto stránky. Pozrite si aktuálnu verziu.

Porovnať s aktuálnou verziou Zobraziť históriu stránky

Verzia 1 Aktuálny »

%XML_GetElementText function


Function
The function returns a text string stored in XML element.
Declaration
TEXT %XML_GetElementText(
   INT in node,
   TEXT in element,
 [ TEXT in namespace := "" ]
 )

Parameters
node Handle to parent XML nod or XML list.
element Name of element, from which a text is obtained.
namespace Optional parameter that defines the name of namespace or prefix of XML element. The value "*" is used, when there is not necessary explicitly take into account namespace and the searching is done only by the element name.

Return value
 
Description
The function returns a text string stored in XML element, which is defined by the name of element and namespace or its prefix. If more than one element match the defined parameters, the function returns invalid value.
The searching is done recursively to the depth, therefore it is recommended to place the handle to a parent element as close as possible to the required XML element in the hierarchical XML structure. If the function returns an invalid result, you may find out the information about error by calling the function %XML_GetLastErrorMessage.
Example
TEXT _errorCodeText 
 TEXT _text 
 _text := %XML_GetElementText(_doc,"td","h")
 IF (!_text\VLD) THEN 
 _errorCodeText := %XML_GetLastErrorMessage()
 ENDIF 

  • Žiadne štítky