"" Then
Dim minnum As Long
Dim maxnum As Long
minnum = Me.最小值
maxnum = Me.最大值
If minnum > maxnum Then
MsgBox "最小值不能大于最大值"
End If
Randomize
Me.随机数 = Int(minnum + (maxnum - minnum + 1) * Rnd())
Else
MsgBox "请输入范围"
End If
End Sub" />
视频描述:
"" Then
Dim minnum As Long
Dim maxnum As Long
minnum = Me.最小值
maxnum = Me.最大值
If minnum > maxnum Then
MsgBox "最小值不能大于最大值"
End If
Randomize
Me.随机数 = Int(minnum + (maxnum - minnum + 1) * Rnd())
Else
MsgBox "请输入范围"
End If
End Sub" class="form-control" readonly="" placeholder="">