# TextInput Clear on Mouse Click

**URL:** <https://forum.kirupa.com/t/textinput-clear-on-mouse-click/278272>\
**Category:** flash\
**Created:** [December 25, 2008, 9:09am UTC](https://forum.kirupa.com/t/textinput-clear-on-mouse-click/278272 "2008-12-25T09:09:52Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![shebimangalath](https://avatars.discourse-cdn.com/v4/letter/s/e0b2c6/32.png) [@shebimangalath](https://forum.kirupa.com/u/shebimangalath)\
**Post date:** [December 25, 2008, 9:09am UTC](https://forum.kirupa.com/t/textinput-clear-on-mouse-click/278272/1 "2008-12-25T09:09:52Z")

</div>

Could you please give me the code for “TextInput Clear on Mouse Click”

Here is my test :-

```auto
 
import fl.controls.TextInput;
 
var ti:TextInput = new TextInput();
addChild(ti);
ti.text = "Hello World";
 
ti.addEventListener(Event.CHANGE, textEntered);
 
function textEntered(e:Event){
 ti.text = "";
}

```

It is not working with mouse click… plss help me…
