I have a submit button on a page and i have 3 text boxes.

i want to make this, when the button is pressed,

text4.value ((text3*3)/text2)

but i don´t know how the code to know when the button is presed and i don´t know id this code above is valid.

i realy need help.