📄 form6.frm
字号:
VERSION 5.00
Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCT2.OCX"
Begin VB.Form Dialog
BorderStyle = 3 'Fixed Dialog
Caption = "修改采集频率"
ClientHeight = 1260
ClientLeft = 5625
ClientTop = 4695
ClientWidth = 3705
Icon = "form6.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1260
ScaleWidth = 3705
ShowInTaskbar = 0 'False
Begin MSComCtl2.UpDown UpDown1
Height = 495
Left = 3360
TabIndex = 4
Top = 120
Width = 240
_ExtentX = 423
_ExtentY = 873
_Version = 393216
Value = 1000
Max = 65535
Min = 100
Enabled = -1 'True
End
Begin VB.TextBox Text1
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 2520
TabIndex = 3
Text = "500"
Top = 180
Width = 855
End
Begin VB.CommandButton CancelButton
Caption = "取消"
Height = 375
Left = 1680
TabIndex = 1
Top = 720
Width = 1215
End
Begin VB.CommandButton OKButton
Caption = "确定"
Height = 375
Left = 240
TabIndex = 0
Top = 720
Width = 1215
End
Begin VB.Label Label1
Caption = "请输入新的采集频率:"
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00C00000&
Height = 255
Left = 120
TabIndex = 2
Top = 240
Width = 2415
End
End
Attribute VB_Name = "Dialog"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub CancelButton_Click()
Unload Me
Form2.Timer1.Enabled = True
End Sub
Private Sub Form_Load()
Dim lenth As Integer
Text1.Text = Str(Form2.Timer1.Interval)
lenth = Len(Text1.Text)
Text1.SelStart = 0
Text1.SelLength = lenth
End Sub
Private Sub OKButton_Click()
Dim a As Long
a = Val(Text1.Text)
If a < 100 Or a > 65535 Then
MsgBox "设置数值越限!", 64, "错误"
Exit Sub
End If
Form2.Timer1.Interval = Int(a)
Form2.Timer1.Enabled = True
Unload Me
End Sub
Private Sub Text1_Change()
Dim a As Long
a = Val(Text1.Text)
If a > 100 And a < 65535 Then
UpDown1.Value = Val(Text1.Text)
End If
End Sub
Private Sub UpDown1_Change()
Text1.Text = Str(UpDown1.Value)
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -