# Get and loop through XML File

**URL:** <https://forum.kirupa.com/t/get-and-loop-through-xml-file/304730>\
**Category:** flash\
**Created:** [February 12, 2010, 5:00pm UTC](https://forum.kirupa.com/t/get-and-loop-through-xml-file/304730 "2010-02-12T17:00:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![shapper](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@shapper](https://forum.kirupa.com/u/shapper)\
**Post date:** [February 12, 2010, 5:00pm UTC](https://forum.kirupa.com/t/get-and-loop-through-xml-file/304730/1 "2010-02-12T17:00:09Z")

</div>

Hello,

I need to get a XML file from a url:  
[http://www.domain.com/Regions/List](http://www.domain.com/Regions/List)

The XML file has the following format:

```auto

<Regions>
  <Region>
    <Id>1</Id>
    <Name>Lisbon</Name>
    <Active>True</Active>
    <Count>10</Count>
  </Region>
  <Region>
    <Id>2</Id>
    <Name>Paris</Name>
    <Active>False</Active>
    <Count>5</Count>
  </Region>
<Regions>

```

How can I load the file and loop through each Region and get its values?  
For each iteraction I need to perform some action with each region values.

Note: Id is an Int, Name is a String, Active is Boolean and Count is an Int.

Thank You,  
Miguel
