?? form1.frm
字號:
VERSION 5.00
Begin VB.Form Form1
BackColor = &H00C0C0C0&
Caption = "動態卷簾式窗體演示"
ClientHeight = 7590
ClientLeft = 8325
ClientTop = 405
ClientWidth = 3570
LinkTopic = "Form1"
ScaleHeight = 7590
ScaleWidth = 3570
Begin VB.CommandButton Command2
BackColor = &H00FFC0C0&
Caption = "退出"
Height = 360
Left = 1785
Style = 1 'Graphical
TabIndex = 2
Top = 0
Width = 1785
End
Begin VB.CommandButton Command1
BackColor = &H00FFC0C0&
Caption = "窗體伸縮"
Height = 360
Left = 0
Style = 1 'Graphical
TabIndex = 1
Top = 0
Width = 1785
End
Begin VB.Timer Timer1
Interval = 300
Left = 2000
Top = 450
End
Begin VB.Label Label1
BackColor = &H00C0C0C0&
Caption = "注意: 請將鼠標移出窗體,您會看到意想不到的效果!"
BeginProperty Font
Name = "宋體"
Size = 15.75
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H0000FFFF&
Height = 6615
Left = 165
TabIndex = 0
Top = 525
Width = 3225
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Declare Function GetCursorPos Lib "user32" (lpPoint As POINTAPI) As Long
Private Type POINTAPI
X As Long
Y As Long
End Type
Private Sub Timer1_Timer() '動態延伸窗體
Dim n As POINTAPI
GetCursorPos n
If n.X > 300 Then
For I = 0 To 8000
Me.Height = Me.Height + 2
Next I
Else
If Me.Height > 450 Then
For I = 0 To 8000
Me.Height = Me.Height - 2
Next I
End If
End If
End Sub
Private Sub Command1_Click() '收縮窗體
If Me.Height > 450 Then
For I = 0 To 8000
Me.Height = Me.Height - 2
Next I
End If
End Sub
Private Sub Command2_Click()
End
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -