【VB开源代码栏目提醒】:网学会员VB开源代码为您提供Ex6_5.frm参考,解决您在Ex6_5.frm学习中工作中的难题,参考学习。
VERSION 5.00
Begin VB.Form Ex6_5
Caption = "Form1"
ClientHeight = 1950
ClientLeft = 60
ClientTop = 450
ClientWidth = 3420
LinkTopic = "Form1"
ScaleHeight = 1950
ScaleWidth = 3420
StartUpPosition = 3 '窗口缺省
Begin VB.TextBox Text1
Height = 615
Left = 600
TabIndex = 1
Text = "Text1"
Top = 360
Width = 2295
End
Begin VB.CommandButton Command1
Caption = "Command1"
Height = 375
Left = 960
TabIndex = 0
Top = 1200
Width = 1215
End
End
Attribute VB_Name = "Ex6_5"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Dim vnt As Variant
'设置缺省属性 (Text) 为"hello"。
Text1 = "hello"
'把对 Text1 的引用放入 Variants 。
Set vnt = Text1
'显示 Text1 的缺省属性,并且给出
'Variants 包含对象引用。
MsgBox vnt, , "IsObject? " & IsObject(vnt)
'试图设置 Text1 的缺省属性。
vnt = "goodbye"
MsgBox vnt, , "IsObject? " & IsObject(vnt)
End Sub
上一篇:
Ex6_4.frm
下一篇:
带心行图案的把手水杯设计