# Converting data to string

**URL:** <https://forum.kirupa.com/t/converting-data-to-string/271772>\
**Category:** Uncategorized\
**Created:** [September 28, 2008, 6:54am UTC](https://forum.kirupa.com/t/converting-data-to-string/271772 "2008-09-28T06:54:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![npgames](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/npgames/32/2914_2.png) [@npgames](https://forum.kirupa.com/u/npgames)\
**Post date:** [September 28, 2008, 6:54am UTC](https://forum.kirupa.com/t/converting-data-to-string/271772/1 "2008-09-28T06:54:35Z")

</div>

**SOLVED**

im trying to use loaded data from xml and make it a string so i can clip out parts of the data i dont want. i can load the data and place it into a var but i cant get it to become a string. when i check what kind of data it is, it says its an object. i tryed using “toString” but then it calls the data a function. not sure what to do.

```auto

var portal:XML = new XML();
portal.ignoreWhite = true;
portal.onLoad = function(success) {
i = 7;
portal_games = [];
portal_thumb = [];
while (i<12) {
		
trace(this.childNodes[0].childNodes*.childNodes[6]);
//returns <media:thumbnail url="http://cdn.mochiads.com/c/g/bomb-jack/_thumb_100x100.jpg" width="100" height="100" />
		
Text = this.childNodes[0].childNodes*.childNodes[6];
Text2 = Text.toString;
trace(typeof (Text2));
//returns "object"
//trace(Text2)
i += 1;
}
};
portal.load("http://www.mochiads.com/feeds/games/a8eb721321dc3820/action/all?limit=5");

```
