%XML_ELEM_REMOVEATTRIBUTES

Remove all attributes from an XML element

WTSupported in traditional Synergy on Windows
WNSupported in Synergy .NET on Windows
USupported on UNIX
VSupported on OpenVMS
status = %XML_ELEM_REMOVEATTRIBUTES(element)

Return value

status

One of the following values:

XML_SUCCESS = The attributes are removed successfully.

XML_FAIL = The attributes are not removed successfully.

Arguments

element

The XML element instance whose attributes will be removed. (XML_ELEM_TYPE)

Discussion

This function is defined as ^VAL.

Examples

The following example removes all of the attributes for the CompanyABC child of the root element.

    doc         ,XML_DOC_TYPE
    root        ,XML_ELEM_TYPE
    elem        ,XML_ELEM_TYPE
    children    ,XML_ELEMLIST_TYPE
    findstr     ,a30
    
    root = %xml_doc_getroot(doc)
    children = %xml_elem_children(root)
    findstr = "CompanyABC"
    elem = %xml_elemlist_findtag(children, %atrim(findstr))

    xcall xml_elem_removeattributes(elem)