text3.text=(val(text1.text)+val(text2.text))/2
先在form上建两个文本框TEXT1、TEXT2,TEXT3双击command1,在click事件里面写dim a as doubletext3.text = string((double(text1.text) + double(text2.text))/2)