首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
在窗体上画一个名称为Command1的命令按钮和3个名称为Label1、Label2、Label3的标签,然后编写如下程序段: Private x As Integer Private Sub Command1_Click(
在窗体上画一个名称为Command1的命令按钮和3个名称为Label1、Label2、Label3的标签,然后编写如下程序段: Private x As Integer Private Sub Command1_Click(
admin
2013-05-12
35
问题
在窗体上画一个名称为Command1的命令按钮和3个名称为Label1、Label2、Label3的标签,然后编写如下程序段: Private x As Integer Private Sub Command1_Click( ) Static y As Integer Dim z As Integer n =10 z = n+z y=y+z x=x+z LabelCaption = x LabelCaption = y LabelCaption = z End Sub 运行程序,连续3次单击命令按钮后,则3个标签中显示的内容是( )。
选项
A、10 10 10
B、30 30 30
C、30 30 10
D、10 30 30
答案
4
解析
本题中变量x是用Dim声明的模块级变量,变量Y是用Static声明的过程级变量,而变量z是用Dim声明的过程级变量。第一次单击命令按钮后,3个标签中分别显示10,10,10;第二次单击命令按钮后,3个标签中分别显示20、20、10;第三次单击命令按钮后,3个标签中分别显示30,30,10。答案为C。
转载请注明原文地址:https://jikaoti.com/ti/imV0FFFM
本试题收录于:
二级Access题库NCRE全国计算机二级分类
0
二级Access
NCRE全国计算机二级
相关试题推荐
Access窗体中的文本框控件分为()。
以下内容不属于算法程序所占的存储空间的是()。
有一个VBA计算程序的功能如下,该程序用户界面由4个文本框和3个按钮组成。4个文本框的名称分别为:Text1、Text2、Text3和Text4。3个按钮分别为:清除(名为Command1)、计算(名为Command2)和退出(名为Command3)。窗体
定义了二维数组A(2to5,5),该数组的元素个数为()。(2004年9月)
假定窗体的名称为fmTest,则把窗体的标题设置为“AccessTest”的语句是()。
以下是某个报表的设计视图。根据视图内容,可以判断出分组字段是()。
在查询中,默认的字段显示顺序是()。
执行下面的程序,消息框的输出结果是【】。OptionBaselPrivateSubCommandlClick()Dima(10),P(3)AsIntegerk=5Fori=1To1
SQL的基本命令中,插入数据命令所用到的语句是()。
SQL语言中提供了SELECT语句,用来进行数据库的【】。
随机试题
中国饭菜的烹调以配料严谨、刀工精致、调味独特、善控火候、技法多变而见长,但选料丰富,不太考究。()
2000年1月29日,根据《生物多样性公约》订立的议定书是【】
经营单位组合分析法综合考虑的因素是___________和该经营单位在市场上的相对竞争地位。
痰迷心窍证与痰火扰心证均可出现的临床表现是
该病人中医诊断是:该病的首选热重于湿方药是:
芹盐
TBT协议对技术法规的定义是()规定产品特性或加工和生产方法的文件。
下列关于概述法,说法正确的是()。
程序的3种基本控制结构是
FourWaystoBeHappierA)IftherewereaDr.Happiness,wouldyourushtogetinlinetoseehim,especiallyifhisprescriptio
最新回复
(
0
)