# Textbox clear on click

**URL:** <https://forum.inductiveautomation.com/t/textbox-clear-on-click/87982>\
**Category:** Ignition\
**Tags:** ignition81, perspective\
**Created:** [March 27, 2024, 4:55pm UTC](https://forum.inductiveautomation.com/t/textbox-clear-on-click/87982 "2024-03-27T16:55:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ryan\_Craig](https://avatars.discourse-cdn.com/v4/letter/r/45deac/32.png) [@Ryan\_Craig](https://forum.inductiveautomation.com/u/Ryan_Craig)\
**Post date:** [March 27, 2024, 4:55pm UTC](https://forum.inductiveautomation.com/t/textbox-clear-on-click/87982/1 "2024-03-27T16:55:44Z")

</div>

I am trying to simple clear a text box when it is click on. The script I have seems to work fine and delete the text within the props but it doesn't delete the value within the actualy text box.

Here is my code:

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/b/a/ba18b583ce638185b23271720d34a9ae3b28dcf8.png)

And this is what happens when I click on the text box:

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/3/f3b8895ab5732dc8bbcc0b9be411224569cdc1b1.png)

it shows the text value as nothing but the actual value show doesn't delete. It does delete once I click off it again though.

Any ideas?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 27, 2024, 5:01pm UTC](https://forum.inductiveautomation.com/t/textbox-clear-on-click/87982/2 "2024-03-27T17:01:49Z")

</div>

Clicking on it gives it focus. Which then rejects/defers updates, because your props say so.
