Can these be done in vbscript or do I have to use javascript

1) How do I create a button, so that when pressed it calls a function.The function I want to write would be to save the data, or go back to the previous screen. How would I do that??

2) Can I do validation on a text box to see if the user is entering numeric data??

Thanks

Reggie