Vb选择结构 问题,错在哪里?

2025-12-16 11:51:54
推荐回答(3个)
回答1:

Private Sub command1——Click()应该为Private Sub command1—Click()

Dim m As Single
Dim p As Integer
m = Val(Test1.Test)应该为
m = Val(Text1.Text)
If m >= 200 Then
p = m * 0.1
Else
p = 0
End If
Test2.Test = p应该为
Text2.Text = p

Print Test2.Test应该为
Print Text2.Text
End Sub

回答2:

Test1.Test
text1.text

回答3:

输入 错误
里面的 test1 换成 text1
test2 换 text2

Private Sub command1——Click() 改成

Private Sub Command1_Click()