# Changing the text in the textfield

**URL:** <https://forum.kirupa.com/t/changing-the-text-in-the-textfield/322758>\
**Category:** flash\
**Created:** [June 2, 2011, 6:55am UTC](https://forum.kirupa.com/t/changing-the-text-in-the-textfield/322758 "2011-06-02T06:55:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeponkz](https://avatars.discourse-cdn.com/v4/letter/j/d07c76/32.png) [@jeponkz](https://forum.kirupa.com/u/jeponkz)\
**Post date:** [June 2, 2011, 6:55am UTC](https://forum.kirupa.com/t/changing-the-text-in-the-textfield/322758/1 "2011-06-02T06:55:31Z")

</div>

I want to change the text in textfield1 with the inputted text in textfield2…

for example, the text in textfield1 is “HELLO” i want to make it “HI” by inputing “HI” in textfield2 after clicking the change button the “HELLO” text will replace by “HI”

changeButton.addEventListener (MouseEvent.CLICK, onClick)  
{  
textfield1.text = textfield2.text  
}

not working… what should i do? any help pls?? thanks!
