dim a!,b!,c& a=val(text1.text) b=val(text3.text) c=text2.text if not isnumeric(text1) or not isnumeric(text3) then msgbox"输入有误!请重新输入!" text1="" text2="" text3="" end if select case c case "+" text4.text=a+b case "-" text4.text=a-b case "×" text4.text=a*b case "÷" text4.text=a/b end select end sub