# XML Get Child Element List

Gets the specified child element from a specified XML structure.

Action available for the following operating systems:

![](/files/-MAlQBZuuTnc6hyzKSVQ)

### Parameters

* **XML** <*string*> - The control, variable or a string that represents a XML file.
* **Remove Name's Prefix** - This parameter allows user to define to remove the name's prefix or not. It can be one of:
  * 1\. Yes
  * 2\. No

*Targets*

* **List of Child Elements** - Control or variable to save the list of child elements.
* **Number of Child Elements** - Control or variable to save the number of listed child elements.

*Return*

* **Items separator** <*string*> - The string separator to the list of child elements.

### Usage

Consider the following XML files:

```
<m:AllForwardsResult>
        <m:string>Aleksandr Kerzhakov</m:string>
        <m:string>Alex Oxlade-Chamberlain</m:string>
        <m:string>Álvaro Negredo</m:string>
        <m:string>André Schürrle</m:string>
        <m:string>Andrei Arshavin</m:string>
        <m:string>Andriy Shevchenko</m:string>
        <m:string>Andriy Voronin</m:string>
        <m:string>Andriy Yarmolenko</m:string>
        <m:string>Andy Carroll</m:string>
        <m:string>Antonio Cassano</m:string>
</m:AllForwardsResult>
```

This XML is saved on VAR(XMLResponse).

```
<soap:Body>
    <m:AllForwardsResponse xmlns:m="http://footballpool.dataaccess.eu">
      <m:AllForwardsResult>
        <m:string>Aleksandr Kerzhakov</m:string>
        <m:string>Alex Oxlade-Chamberlain</m:string>
        <m:string>Álvaro Negredo</m:string>
        <m:string>André Schürrle</m:string>
        <m:string>Andrei Arshavin</m:string>
        <m:string>Andriy Shevchenko</m:string>
        <m:string>Andriy Voronin</m:string>
        <m:string>Andriy Yarmolenko</m:string>
        <m:string>Andy Carroll</m:string>
        <m:string>Antonio Cassano</m:string>
      </m:AllForwardsResult>
    </m:AllForwardsResponse>
</soap:Body>
```

This XML is saved on VAR(XMLResponse1).

#### Example 1

|                              |                  |
| ---------------------------- | ---------------- |
| **XML**                      | VAR(XMLResponse) |
| **Remove Name´s Prefix**     | YES              |
| **List of Child Elements**   | VAR(Elements)    |
| **Number of Child Elements** | VAR(NElements)   |
| **Items Separator**          | "<13>"           |

**Result:**

| **Variables**      | **Content**                                                             |
| ------------------ | ----------------------------------------------------------------------- |
| **VAR(Elements)**  | <p>stringstringstringstringstring<br>stringstringstringstringstring</p> |
| **VAR(NElements)** | 10                                                                      |

#### Example 2

|                              |                   |
| ---------------------------- | ----------------- |
| **XML**                      | VAR(XMLResponse1) |
| **Remove Name´s Prefix**     | NO                |
| **List of Child Elements**   | VAR(Elements)     |
| **Number of Child Elements** | VAR(NElements)    |
| **Items Separator**          | "<13>"            |

**Result:**

| **Variables**      | **Content**           |
| ------------------ | --------------------- |
| **VAR(Elements)**  | m:AllForwardsResponse |
| **VAR(NElements)** | 1                     |

{% hint style="info" %}
The parameter **Items Separator** is coded.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.sysdevmobile.com/kalipso5/developing/form/actions/actions-description/group-communications/xml-get-child-element-list.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
