# Clear imput text box

**URL:** <https://forum.kirupa.com/t/clear-imput-text-box/221311>\
**Category:** Uncategorized\
**Created:** [April 3, 2007, 9:56am UTC](https://forum.kirupa.com/t/clear-imput-text-box/221311 "2007-04-03T09:56:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![fileslasher](https://avatars.discourse-cdn.com/v4/letter/f/4da419/32.png) [@fileslasher](https://forum.kirupa.com/u/fileslasher)\
**Post date:** [April 3, 2007, 9:56am UTC](https://forum.kirupa.com/t/clear-imput-text-box/221311/1 "2007-04-03T09:56:35Z")

</div>

Just wondering how to clear an imput text box with a button after the user has typed something in it.  
I tried this but it doesnt work.  
on(press) {  
imput\_txt.text = “”;  
}

The text box is assigned to:  
\_root.userAnswer = Number(imput\_txt.text);
