# Unloading a textfile completely before loading next one

**URL:** https://forum.kirupa.com/t/unloading-a-textfile-completely-before-loading-next-one/298494
**Category:** Uncategorized
**Created:** [October 20, 2009, 6:28am UTC](https://forum.kirupa.com/t/unloading-a-textfile-completely-before-loading-next-one/298494 "2009-10-20T06:28:12Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![ram\_son](https://avatars.discourse-cdn.com/v4/letter/r/ebca7d/32.png) [@ram\_son](https://forum.kirupa.com/u/ram_son)
#### Post date: [October 20, 2009, 6:28am UTC](https://forum.kirupa.com/t/unloading-a-textfile-completely-before-loading-next-one/298494/1 "2009-10-20T06:28:12Z")

</div>

In have an application that uses buttons t0 load different text files. The problem is when I load the second text file I still get variables from the first one showing. To clarify things, suppose I load a file that displays variables 1 through 5 randomly when I click one button, then I click a second button in order to load a file that displays 6 through 10. The problem is that I still get some variables from 1-5 when I want to get only 6-10. Is the first file kept in memory or something? How do I unload or clear the temp/memory where the content of the first file is held. I hope this one turns to be a small problem.
