首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
要求当鼠标在图片框P1中移动时,立即在图片框中显示鼠标的位置坐标。下面能正确实现上述功能的事件过程是( )。
要求当鼠标在图片框P1中移动时,立即在图片框中显示鼠标的位置坐标。下面能正确实现上述功能的事件过程是( )。
admin
2020-07-22
28
问题
要求当鼠标在图片框P1中移动时,立即在图片框中显示鼠标的位置坐标。下面能正确实现上述功能的事件过程是( )。
选项
A、Private Sub P1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Print X, Y
End Sub
B、 Private Sub P1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
Picture.Print X, Y
End Sub
C、 Private Sub P1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
P1.Print X, Y
End Sub
D、 Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
P1.Print X, Y
End Sub
答案
C
解析
当鼠标在图片框P1中移动时,就会触发P1的鼠标移动事件,即P1_MouseMove事件,故排除B选项;鼠标在图片框P1中移动时,立即在图片框中显示鼠标的位置坐标,说明是在图片框上输出数据,所以用P1的Print语句实现。故C选项正确。
转载请注明原文地址:https://jikaoti.com/ti/ZlS0FFFM
本试题收录于:
二级VB题库NCRE全国计算机二级分类
0
二级VB
NCRE全国计算机二级
相关试题推荐
(1)在考生文件夹下有一个工程文件sjt3.vbp,在程序运行时,单击“输入整数”按钮,可以从键盘输入一个整数,并在窗体上显示此整数的所有不同因子和因子个数。如图3.158(a)是输入53后的结果,如图3.158(b)是输入100的结果。已经给出了全部控件
以下程序段的功能是:从文本框中输入一个数值,如果该数值满足“除以4余1,除以5余2”的条件,则在窗体上输出文本框中的数值,否则,将焦点定位在文本框中,并清除文本框的内容,在横线处应填写()。PrivateSubCommand1_Click()
下列程序执行后,变量x的值为()。Dima,b,C,dAsSingleDimxAsSinglea=10:b=30:c=400Ifb>aThend=a:a=b:b=dEndIf
如果在VisualBasic集成环境中没有打开属性窗口,下列可以打开属性窗口的操作是( )。
窗体上有2个名称分别为Text1和Text2的文本框。编写如下程序:PrivateSubForm_Load()Text1.Text=""Text2.Text=""EndSubPrivateSubCommand1_Cl
设置定时器控件的Interval属性为2000,Enabled属性为True,并且有下面的事件过程,程序运行时计算机将发出()次Beep声。SubTimer1_Timer()BeepEndSub
对建立良好的程序设计风格,下面描述正确的是()。
已知:x=-6y=39则表达式"y\x*Sgn(x)"的值为( )。
从键盘上输入一个浮点数asingle,利用字符串函数对该数进行处理后,如果输出的内容不是“非浮点数”,则对程序输出的内容分析正确的是()。asingle=InputBox("请输入一个浮点数:")str1$=Str$(asing
窗体上有名称为Commandl的命令按钮和名称为Textl的文本框PrivateSubCommand1_Click()Textl.Text=”程序设计”Text1.SetFocus
随机试题
公共关系策划书的形成要经历一个完整而严密的策划过程:__________、搜集已有资料、进行市场调查、将资料整理成情报、产生策划创意、形成多种方案、优化选择方案等,最终确定下来一个经论证最优秀、最适当的策划方案。
心钠素的第二信使是
低强度激光治疗作用不包括
女性,30岁,痛经10年,原发不孕3年,月经规律,经量中等,痛经显著,需服止痛药,查体:宫骶韧带触痛结节,子宫后位,大小正常,活动差,左附件区触及直径6cm囊肿,活动好。基础体温双相,HSG宫腔大小形态正常,双侧输卵管通畅,CA12545U/L,男方精液
CT图像形成所采用的方式是
患者,男性,48岁,因吞咽食物易梗噎,胸骨后有异物感和烧灼样痛2个月,经纤维食管镜检查证实为食管癌,准备入院手术治疗。既往吸烟15年。患者行食管癌根治术后1个月又出现吞咽不畅,可能的原因是
投资建设项目管理环境可分为一般环境和具体环境,其中一般环境包括的外部条件有()。
某汽车企业生产15-8型汽车,年产量10000台,每台15-8型汽车需要A1-001型齿轮1件。该企业年初运用在制品定额法来确定本年度车间的生产任务,相关信息及数据见下表:根据以上资料,回答下列问题:根据市场和企业状况,装配车间15—8型汽车的投入
公文中无论是张贴或者登报的通告,落款处必须写明()。
家庭服务网关是智能家庭中的关键设备,是家庭内部智能设备与外部网络(如因特网)连接的桥梁。现需要设计的家庭服务网关基本功能具体描述如下:a、家庭服务网关具有一个以太网接口(对外连接),一个WiFi通信接口(对内连接),一个RS一485总线接口(对内连接)。
最新回复
(
0
)