vb实时错误6溢出?

2025-03-04 22:40:27
推荐回答(1个)
回答1:

Private Sub Command1_Click()
Dim a As Long, b As Long, x As Long, c As Double
a = Val(Text1.Text)
b = Val(Text2.Text)
x = Val(Text4.Text)
c = x * b / 1200
Text3.Text = c
Text4.Text = x + a + c
Text5.Text = Val(Text5.Text) + 1
End Sub