首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
设窗体上有一个标签Label 1和一个计时器Timer1,Timer1的Interval属性被设置为1000, Enabled属性被设置为True。要求程序运行时每秒在标签中显示一次系统当前时间。下列可以实现上述要求的事件过程是( )。
设窗体上有一个标签Label 1和一个计时器Timer1,Timer1的Interval属性被设置为1000, Enabled属性被设置为True。要求程序运行时每秒在标签中显示一次系统当前时间。下列可以实现上述要求的事件过程是( )。
admin
2013-04-11
37
问题
设窗体上有一个标签Label 1和一个计时器Timer1,Timer1的Interval属性被设置为1000, Enabled属性被设置为True。要求程序运行时每秒在标签中显示一次系统当前时间。下列可以实现上述要求的事件过程是( )。
选项
A、 Private Sub Timer1_Timer() Labell.Caption=True End Sub
B、Private Sub Timer1_Timer() Labell.Caption=Time$ End Sub
C、Private Sub Timer1_Timer() Labell.Interval=1 End Sub
D、Private Sub Timer1_Timer() For k=1 To Timerl.Interval Label1.Caption=Timer Next K End Sub
答案
B
解析
本题考查的考点是有关计时器的。计时器的Interval属性决定了每隔多长时间触发一次Timer事件。本题中Interval设置为 1000,即每1秒触发一次Timer事件。在事件中把标签的Caption属性设置成为当前时间,用Time函数可以得到当前时间。
转载请注明原文地址:https://jikaoti.com/ti/z0O0FFFM
本试题收录于:
二级VB题库NCRE全国计算机二级分类
0
二级VB
NCRE全国计算机二级
相关试题推荐
在窗体上画一个名称为Command1的命令按钮,然后编写如下事件过程:PrivateSubCommand1_Click()Forn=1To20IfnMod3<>Thenm=m+n\3
在窗体上画—个名称为Command1的命令按钮,然后编写如下事件过程:PrivateSubCommand1_click()DimaAsInteger,sAsIntegera=8s=1
如果—个工程含有多个窗体及标准模块,则以下叙述中错误的是______。
设a=10,b=5,c=1,执行语句Printa>b>c后,窗体上显示的是______。
把窗体的KeyPreview属性设置为True,并编写如下两个事件过程:
在窗体上画一个命令按钮,然后编写如下事件过程:OptionBase1PrivateSubCommand1_click()Dimaa=Array(1,2,3,4)j=1For
在窗体上画尸-个命令按钮,其名称为Command1,然后编写如下事件过程:PrivateSubCommand1_Click()Fori=1to4Ifi=1Thenx=iIfi<=4
在窗体上画一个文本框,一个命令按钮和一个标签,其名称分别为Text1、Command1和Label1,文本框的Text1属性设置为空白,然后编写如下事件过程:PrivateSubCommand1_Click()x=Int(Val(
随机试题
常在夜间或清晨发作,发作时伴有心电图ST段抬高,发作时间较长,主要由冠状动脉痉挛所致,属于不稳定型心绞痛中的()
男,8岁。2个月前因左侧脓胸行胸腔闭式引流术,现患儿食欲缺乏,低热,肋间隙变窄,胸片肺内未见明显异常。治疗应选择
A.真皮的网状层B.黄韧带C.皮下组织D.肌腱E.淋巴结网状组织多见于
属于地块控制性指标内容的是()等。
关于日常生活覆盖储备金的描述,()的说法是错误的。
在年末财产清查中甲公司发现一台全新的未入账的设备(即资产盘盈),其同类设备的市场价格为5万元。故认定该设备的价值为5万元,这是会计计量的()属性。
商业银行开展理财业务经营活动应符合的审慎监管要求不包括()。
WhenmyfamilymovedtoAmericain2010fromasmallvillageinGuangdong,China,webroughtnotonlyourluggage,butalsoour
学生在教师指导下,运用一定的仪器设备获取知识的教学方法是()。
根据下面材料回答问题。2012年该市文化产业从业人员人均生产总值比上一年约减少了()。
最新回复
(
0
)