# Clear textbox on rolloff..?

**URL:** <https://forum.kirupa.com/t/clear-textbox-on-rolloff/54285>\
**Category:** Uncategorized\
**Created:** [June 12, 2004, 10:30pm UTC](https://forum.kirupa.com/t/clear-textbox-on-rolloff/54285 "2004-06-12T22:30:29Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![johnnyFlash](https://avatars.discourse-cdn.com/v4/letter/j/2bfe46/32.png) [@johnnyFlash](https://forum.kirupa.com/u/johnnyFlash)\
**Post date:** [June 12, 2004, 10:30pm UTC](https://forum.kirupa.com/t/clear-textbox-on-rolloff/54285/1 "2004-06-12T22:30:29Z")

</div>

Hi again, i’d just like to start off saying that these forums are super-helpful 🙂

I’m having trouble with textboxs. I have text loaded randomly from a .txt file on the rollover of a button:

```auto

 on (rollOver) {
 	loadText = new loadVars();
 	loadText.load("txtfile.txt");
 	loadText.onLoad = function(OK) {
 		if (OK) {
 			myText.Text = this["text"+(Math.floor(Math.random()*4)+1)];
 		}
 	};
 }
 

```

But i need myText box to clear once the mouse is rolled off. So…i just thought it would be something simple like:

```auto

 on(rollOut) {
 	myText = "";
 {
 

```

But, it doesn’t work at all. What’s my problemo? :huh:
