# XML values, nodeNames toStirng

**URL:** <https://forum.kirupa.com/t/xml-values-nodenames-tostirng/281066>\
**Category:** flash\
**Created:** [February 4, 2009, 3:23pm UTC](https://forum.kirupa.com/t/xml-values-nodenames-tostirng/281066 "2009-02-04T15:23:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pettt\_cz](https://avatars.discourse-cdn.com/v4/letter/p/919ad9/32.png) [@Pettt\_cz](https://forum.kirupa.com/u/Pettt_cz)\
**Post date:** [February 4, 2009, 3:23pm UTC](https://forum.kirupa.com/t/xml-values-nodenames-tostirng/281066/1 "2009-02-04T15:23:37Z")

</div>

Is there a way to get this:  
“red, blue, green”

from this:

```auto

<colorSet>
<color>red</color>
<color>blue</color>
<color>green</color>
</colorSet>

```

**without iteration ?**

… and this:  
“colorA, colorB, colorC”

from this:

```auto

<colorSet>
<colorA>red</colorA>
<colorB>blue</colorB>
<colorC>green</colorC>
</colorSet>

```

**…again, not in the loop ?**  
I was hoping the “XML.toString” would do it for me, but i need only the values or nodeNames. I can get that via iteration, i was just hoping for les “costly” way…

thanx all
