STATIC PUBLIC SUB Main()
hForm AS Fmain
hForm = NEW Fmain
hForm.show
END
PUBLIC SUB Button1_Click()
x AS Integer
x = CInt(TextBox1.Text) + CInt(TextBox2.Text)
'this throws an error if the input does not exactly
'looks like an integer!
'so better use val() if you're not sure.