📄 form2.frm
字号:
VERSION 5.00
Begin VB.Form Form2
BorderStyle = 3 'Fixed Dialog
Caption = " 自定义雷区"
ClientHeight = 1770
ClientLeft = 45
ClientTop = 330
ClientWidth = 2865
Icon = "Form2.frx":0000
LinkTopic = "Form2"
LockControls = -1 'True
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1770
ScaleWidth = 2865
ShowInTaskbar = 0 'False
WhatsThisButton = -1 'True
WhatsThisHelp = -1 'True
Begin VB.CommandButton Command1
Caption = "取消"
Height = 375
Index = 1
Left = 1770
TabIndex = 7
Top = 990
Width = 885
End
Begin VB.TextBox Text1
Height = 285
Index = 2
Left = 960
TabIndex = 5
Text = "10"
Top = 1080
Width = 645
End
Begin VB.TextBox Text1
Height = 285
Index = 1
Left = 960
TabIndex = 3
Text = "9"
Top = 720
Width = 645
End
Begin VB.CommandButton Command1
Caption = "确定"
Height = 375
Index = 0
Left = 1770
TabIndex = 0
Top = 360
Width = 885
End
Begin VB.TextBox Text1
Height = 285
Index = 0
Left = 960
TabIndex = 1
Text = "9"
Top = 360
Width = 645
End
Begin VB.Label Label1
Caption = "雷数(&M):"
Height = 225
Index = 2
Left = 150
TabIndex = 6
Top = 1110
Width = 945
End
Begin VB.Label Label1
Caption = "宽度(&W):"
Height = 225
Index = 1
Left = 150
TabIndex = 4
Top = 750
Width = 945
End
Begin VB.Label Label1
Caption = "高度(&H):"
Height = 225
Index = 0
Left = 150
TabIndex = 2
Top = 390
Width = 945
End
End
Attribute VB_Name = "Form2"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub Command1_Click(Index As Integer)
If Index = 0 Then
If Val(Text1(0)) < 9 Then Text1(0) = 9
If Val(Text1(0)) > 24 Then Text1(0) = 24
If Val(Text1(1)) > 30 Then Text1(1) = 30
If Val(Text1(1)) < 9 Then Text1(1) = 9
If Val(Text1(2)) < 10 Then Text1(2) = 10
If Val(Text1(2)) > (Val(Text1(0)) - 1) * (Val(Text1(1)) - 1) Then Text1(2) = (Val(Text1(0)) - 1) * (Val(Text1(1)) - 1)
LeiCol = Val(Text1(1))
LeiRow = Val(Text1(0))
LeiNums = Val(Text1(2))
SetSize LeiRow, LeiCol
End If
Unload Me
End Sub
Private Sub Form_Load()
Text1(0) = LeiRow
Text1(1) = LeiCol
Text1(2) = LeiNums
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -