# Updating an input filed from my class

**URL:** <https://forum.kirupa.com/t/updating-an-input-filed-from-my-class/254030>\
**Category:** Uncategorized\
**Created:** [March 7, 2008, 11:30am UTC](https://forum.kirupa.com/t/updating-an-input-filed-from-my-class/254030 "2008-03-07T11:30:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alber\_Kidd](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@Alber\_Kidd](https://forum.kirupa.com/u/Alber_Kidd)\
**Post date:** [March 7, 2008, 11:30am UTC](https://forum.kirupa.com/t/updating-an-input-filed-from-my-class/254030/1 "2008-03-07T11:30:26Z")

</div>

I want to update a text input from my class the imput tex is called Name\_txt. I get an undefined property error

package {  
import flash.display._;  
import flash.events._;  
import fl.transitions.\*;  
import flash.display.MovieClip;

```
public class qwertyKeyboard extends MovieClip

{
    
    

// constructor
    
public function qwertyKeyboard()
    {
        
    this.addEventListener(MouseEvent.MOUSE_DOWN, addLetter);
    
        
    }
    
    
    public function addLetter(event:MouseEvent):void {
        
        
        
        trace(event.target.name.substr(0,1));
        Name_txt.text="hello";
        Name_txt.border =true;
        
       

        
 

    }
    
}

```

}
