# External text from XML file

**URL:** <https://forum.kirupa.com/t/external-text-from-xml-file/266288>\
**Category:** Uncategorized\
**Created:** [July 18, 2008, 2:38am UTC](https://forum.kirupa.com/t/external-text-from-xml-file/266288 "2008-07-18T02:38:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![nicklavoie](https://avatars.discourse-cdn.com/v4/letter/n/ac91a4/32.png) [@nicklavoie](https://forum.kirupa.com/u/nicklavoie)\
**Post date:** [July 18, 2008, 2:38am UTC](https://forum.kirupa.com/t/external-text-from-xml-file/266288/1 "2008-07-18T02:38:19Z")

</div>

hi I’m making a flash movie that contains about 50 buttons. at the moment, i’ve got each button’s action set to:

on (release) {  
gotoAndPlay(“lots”, 1);  
title = “LOT No. 13”;  
status = “AVAILABLE”;  
price = “Contact Listing Agents for details”;  
}

what I need to do here is call the info from external files. so I’ll have 1.xml, 2.xml, etc. Each one of these xml files will contain the proper info I need pulled when someone clicks on one of the buttons, BUT I do not know how to make this happen. Tutorials have not helped me at all as of yet.

can someone make me a quick sample .xml file and a code snip that I can use on each button? it must include that gotoAndPlay(“lots”, 1); so that I can re-use the same scene i’m using now and the new action should call the proper xml file to load in three variables: (title, status and price) are the variables I’ve got set at the moment.

thanks
