home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Programming Tool Box
/
SIMS_2.iso
/
vb_code2
/
t_button
/
form1.frm
next >
Wrap
Text File
|
1993-11-18
|
3KB
|
138 lines
VERSION 2.00
Begin Form Form1
Caption = "Toolbar Button Demo"
ClientHeight = 1884
ClientLeft = 1704
ClientTop = 1992
ClientWidth = 4140
Height = 2304
Left = 1656
LinkTopic = "Form1"
ScaleHeight = 1884
ScaleWidth = 4140
Top = 1620
Width = 4236
Begin CommandButton Command3
Caption = "Toggle"
Height = 444
Left = 2208
TabIndex = 4
Top = 1248
Width = 1260
End
Begin ToolBarButton TBtn2
Enabled = -1 'True
Height = 540
Left = 672
Picture = FORM1.FRX:0000
Sticky = -1 'True
Toggled = 0 'False
Top = 1200
Width = 588
End
Begin ToolBarButton TBtn1
Enabled = -1 'True
Height = 540
Left = 672
Picture = FORM1.FRX:01FA
Sticky = 0 'False
Toggled = 0 'False
Top = 336
Width = 588
End
Begin CommandButton Command2
Caption = "Hide"
Height = 396
Left = 2208
TabIndex = 1
Top = 672
Width = 1260
End
Begin CommandButton Command1
Caption = "Disable"
Height = 396
Left = 2208
TabIndex = 0
Top = 192
Width = 1260
End
Begin Label lblNormal
Caption = "Sticky"
Height = 204
Index = 1
Left = 672
TabIndex = 3
Top = 960
Width = 876
End
Begin Label lblNormal
Caption = "Normal"
Height = 204
Index = 0
Left = 672
TabIndex = 2
Top = 96
Width = 876
End
End
Sub Command1_Click ()
If TBtn1.Enabled Then
TBtn1.Enabled = False
Command1.Caption = "Enable"
Else
TBtn1.Enabled = True
Command1.Caption = "Disable"
End If
End Sub
Sub Command2_Click ()
If TBtn1.Visible Then
TBtn1.Visible = False
Command2.Caption = "Unhide"
Else
TBtn1.Visible = True
Command2.Caption = "Hide"
End If
End Sub
Sub Command3_Click ()
If TBtn2.Toggled Then
TBtn2.Toggled = False
Command3.Caption = "Toggle"
Else
TBtn2.Toggled = True
Command3.Caption = "UnToggle"
End If
TBtn2.Refresh
End Sub
Sub TBtn1_Click ()
MsgBox "TBtn1_Click", 0, "Click"
End Sub
Sub TBtn2_Click ()
Dim aString As String
aString = "TBtn2_Click is "
If TBtn2.Toggled Then
aString = aString + "Toggled"
Else
aString = aString + "Untoggled"
End If
MsgBox aString, 0, "Click"
End Sub