class to update textbox