关于vb中的inputbox函数
PrivateSubForm_Click()a="请输入数据"b="数据计算"c=InputBox(a,b)d=InputBox(a,b)e=InputBox(a,b)f...
Private Sub Form_Click()
a = "请输入数据"
b = "数据计算"
c = InputBox(a, b)
d = InputBox(a, b)
e = InputBox(a, b)
f = InputBox(a, b)
Dim c As Integer, d As Variant, e As Variant, f As Variant
Print (c + d + e + f), (c + d + e + f) / 2
End Sub
错在哪???? 展开
a = "请输入数据"
b = "数据计算"
c = InputBox(a, b)
d = InputBox(a, b)
e = InputBox(a, b)
f = InputBox(a, b)
Dim c As Integer, d As Variant, e As Variant, f As Variant
Print (c + d + e + f), (c + d + e + f) / 2
End Sub
错在哪???? 展开
4个回答
展开全部
是的
正确的代码为:
Dim
a
As
integer
Dim
b
As
integer
Dim
c
As
integer
a
=
Int(Rnd(10))
b
=
Int(Rnd(10))
c=inputbox("a+b=","请输入答案")
正确的代码为:
Dim
a
As
integer
Dim
b
As
integer
Dim
c
As
integer
a
=
Int(Rnd(10))
b
=
Int(Rnd(10))
c=inputbox("a+b=","请输入答案")
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
Private Sub Form_Click()
a = "请输入数据"
b = "数据计算"
'移到这里
Dim c As Integer, d As Variant, e As Variant, f As Variant
c = InputBox(a, b)
d = InputBox(a, b)
e = InputBox(a, b)
f = InputBox(a, b)
Print (c + d + e + f), (c + d + e + f) / 2
End Sub
a = "请输入数据"
b = "数据计算"
'移到这里
Dim c As Integer, d As Variant, e As Variant, f As Variant
c = InputBox(a, b)
d = InputBox(a, b)
e = InputBox(a, b)
f = InputBox(a, b)
Print (c + d + e + f), (c + d + e + f) / 2
End Sub
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
Private Sub Command3_Click()
Dim c As Integer, d As Variant, e As Variant, f As Variant
a = "请输入数据"
b = "数据计算"
c = InputBox(a, b)
d = InputBox(a, b)
e = InputBox(a, b)
f = InputBox(a, b)
Print (c + d + e + f), (c + d + e + f) / 2
End Sub
把声明变量的句子放在上面,否则就是重复声明了!!
Dim c As Integer, d As Variant, e As Variant, f As Variant
a = "请输入数据"
b = "数据计算"
c = InputBox(a, b)
d = InputBox(a, b)
e = InputBox(a, b)
f = InputBox(a, b)
Print (c + d + e + f), (c + d + e + f) / 2
End Sub
把声明变量的句子放在上面,否则就是重复声明了!!
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询