单选题 窗体上有一个名称为Command1的命令按钮,事件过程如下:
Private Sub Command1_Click()
Dim num As Integer,x As Integer
num=Val(InputBox("请输入一个正整数"))
Select Case num
Case Is>100
x=x+num
Case Is<90
x=num
Case Else
x=x*num
End Select
Print x:
End Sub
运行程序,并在三次单击命令按钮时,分别输入正整数100、90和60,则窗体上显示的内容为______。
【正确答案】 B
【答案解析】[解析] 按钮事件中变量x为过程局部变量,第1次输入100时,Select语句执行Case Else分支,x=x*num=0*100=0。第二次输入90时,Select语句执行case E1se分支,x=x*num=0*90=0。第三次输入60时Select语句执行Case Is<90分支,x=num=60。因此窗体上显示为0 0 60,B选项正确。