?? form0803.frm
字號:
VERSION 5.00
Begin VB.Form Form1
Caption = "繪制矩形"
ClientHeight = 2400
ClientLeft = 60
ClientTop = 450
ClientWidth = 4185
LinkTopic = "Form1"
ScaleHeight = 2400
ScaleWidth = 4185
StartUpPosition = 3 '窗口缺省
Begin VB.PictureBox Picture1
Height = 1695
Left = 2160
ScaleHeight = 1635
ScaleWidth = 1635
TabIndex = 6
Top = 360
Width = 1695
End
Begin VB.Frame Frame1
Height = 1815
Left = 360
TabIndex = 0
Top = 240
Width = 1455
Begin VB.TextBox Text2
Height = 270
Left = 720
TabIndex = 5
Top = 720
Width = 495
End
Begin VB.CommandButton Command1
Caption = "畫圖"
Height = 375
Left = 240
TabIndex = 4
Top = 1200
Width = 975
End
Begin VB.TextBox Text1
Height = 270
Left = 720
TabIndex = 1
Top = 240
Width = 495
End
Begin VB.Label Label2
Caption = "寬="
Height = 255
Left = 240
TabIndex = 3
Top = 720
Width = 375
End
Begin VB.Label Label1
Caption = "長="
Height = 255
Left = 240
TabIndex = 2
Top = 240
Width = 375
End
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub Command1_Click()
'單擊畫圖按鈕
Dim W As Integer, H As Integer
W = Val(Text1.Text)
H = Val(Text2.Text)
If W <> 0 And H <> 0 Then
' Picture1.Line (0, 0)-Step(W, 0)
' Picture1.Line -Step(0, H)
' Picture1.Line -Step(-W, 0)
' Picture1.Line -Step(0, -H)
Picture1.Line (0, 0)-(W, H), , B
End If
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -