📄 form5.frm
字号:
VERSION 5.00
Object = "{3A6644DE-3402-11D9-9DE7-C33FAA87690A}#1.0#0"; "WinXPCEngine.ocx"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Begin VB.Form SysForm
AutoRedraw = -1 'True
BackColor = &H00FF8080&
BorderStyle = 1 'Fixed Single
Caption = "速度设置"
ClientHeight = 2835
ClientLeft = 45
ClientTop = 435
ClientWidth = 6900
Icon = "Form5.frx":0000
LinkTopic = "Form1"
LockControls = -1 'True
MaxButton = 0 'False
MinButton = 0 'False
MouseIcon = "Form5.frx":08CA
MousePointer = 99 'Custom
ScaleHeight = 2835
ScaleWidth = 6900
StartUpPosition = 2 '屏幕中心
Begin VB.Timer Timer1
Left = 6480
Tag = "作者:范轩轩"
Top = 0
End
Begin VB.Frame Frame1
BackColor = &H00FF8080&
Caption = " 预览窗口:"
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H0000FFFF&
Height = 2655
Left = 240
TabIndex = 5
Top = 120
Width = 3015
Begin VB.PictureBox Picture1
Height = 1045
Index = 3
Left = 1560
ScaleHeight = 990
ScaleWidth = 1275
TabIndex = 9
TabStop = 0 'False
Top = 1500
Width = 1335
Begin VB.Image Image1
Height = 1045
Index = 3
Left = 0
Picture = "Form5.frx":1194
Stretch = -1 'True
Top = 0
Width = 1335
End
End
Begin VB.PictureBox Picture1
Height = 1045
Index = 2
Left = 120
ScaleHeight = 990
ScaleWidth = 1275
TabIndex = 8
TabStop = 0 'False
Top = 1500
Width = 1335
Begin VB.Image Image1
Height = 1045
Index = 2
Left = 0
Picture = "Form5.frx":129E3
Stretch = -1 'True
Top = 0
Width = 1335
End
End
Begin VB.PictureBox Picture1
Height = 1045
Index = 0
Left = 1560
ScaleHeight = 990
ScaleWidth = 1275
TabIndex = 7
TabStop = 0 'False
Top = 360
Width = 1335
Begin VB.Image Image1
Height = 1045
Index = 0
Left = 0
Picture = "Form5.frx":23F36
Stretch = -1 'True
Top = 0
Width = 1335
End
End
Begin VB.PictureBox Picture1
Height = 1045
Index = 1
Left = 120
ScaleHeight = 990
ScaleWidth = 1275
TabIndex = 6
TabStop = 0 'False
Top = 360
Width = 1335
Begin VB.Image Image1
Height = 1045
Index = 1
Left = 0
Picture = "Form5.frx":2FC06
Stretch = -1 'True
Top = 0
Width = 1335
End
End
Begin VB.Image Image2
Height = 375
Left = 120
Picture = "Form5.frx":3E0A3
Stretch = -1 'True
ToolTipText = "云南大学"
Top = -50
Width = 375
End
End
Begin VB.CommandButton Command1
BackColor = &H00FF8080&
Cancel = -1 'True
Caption = "取消(&C)"
BeginProperty Font
Name = "宋体"
Size = 9
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 615
Index = 1
Left = 5040
Picture = "Form5.frx":3E78D
Style = 1 'Graphical
TabIndex = 3
ToolTipText = "取消"
Top = 1920
Width = 975
End
Begin VB.CommandButton Command1
BackColor = &H00FF8080&
Caption = "确定(&O)"
Default = -1 'True
BeginProperty Font
Name = "宋体"
Size = 9
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 615
Index = 0
Left = 5040
Picture = "Form5.frx":3EE77
Style = 1 'Graphical
TabIndex = 2
ToolTipText = "确定"
Top = 1080
Width = 975
End
Begin VB.TextBox Text1
BackColor = &H00FF8080&
BeginProperty Font
Name = "宋体"
Size = 21.75
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H0000FFFF&
Height = 405
Left = 4680
MaxLength = 4
TabIndex = 0
Text = "500"
Top = 360
Width = 975
End
Begin MSComctlLib.Slider SliderBar
Height = 2655
Left = 3720
TabIndex = 1
Top = 120
Width = 495
_ExtentX = 873
_ExtentY = 4683
_Version = 393216
Orientation = 1
LargeChange = 1000
SmallChange = 100
Min = 100
Max = 3000
SelStart = 500
TickFrequency = 500
Value = 500
End
Begin WinXPC_Engine.WindowsXPC WindowsXPC1
Left = 3720
Top = 2160
_ExtentX = 6588
_ExtentY = 1085
ColorScheme = 2
Common_Dialog = 0 'False
FrameControl = 0 'False
End
Begin VB.Label Label1
AutoSize = -1 'True
BackColor = &H00FF8080&
BackStyle = 0 'Transparent
Caption = "毫秒"
BeginProperty Font
Name = "宋体"
Size = 18
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00000000&
Height = 360
Left = 5880
TabIndex = 4
Top = 360
Width = 750
End
End
Attribute VB_Name = "SysForm"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit '强制显式声明模块中的所有变量
Private my_Add As Integer '循环次数
Public my_Delay As Integer '时间间隔
Private Sub my_Swap(num1 As Object, num2 As Object) '控件交换
Dim temp As Object
Set temp = num1.Container
Set num1.Container = num2.Container
Set num2.Container = temp
End Sub
Private Sub Command1_Click(Index As Integer)
Select Case Index
Case 0 '确定
If Val(Text1.Text) < 100 Or Val(Text1.Text) > 3000 Then
MsgBox "范围:100~~3000", vbExclamation, "提示"
Text1.SetFocus
Exit Sub
End If
my_Delay = SliderBar.Value
MainForm.my_Ext = True '按下"确定"按钮
Case 1 '取消
MainForm.my_Ext = False '未按下"确定"按钮
End Select
Unload Me
End Sub
Private Sub Form_Load()
WindowsXPC1.InitSubClassing '初始化控件
Timer1.Interval = Val(Text1.Text) '初始化时间间隔
my_Add = 0
End Sub
Private Sub SliderBar_Change()
Timer1.Interval = Val(Text1.Text)
End Sub
Private Sub SliderBar_Scroll()
Text1.Text = SliderBar.Value
Timer1.Interval = Val(Text1.Text)
End Sub
Private Sub Text1_Change()
SliderBar.Value = Val(Text1.Text)
End Sub
Private Sub Text1_GotFocus() '全选文本框内的内容
Text1.SelStart = 0
Text1.SelLength = Len(Text1.Text)
End Sub
Private Sub Text1_KeyPress(KeyAscii As Integer)
If Not IsNumeric(Chr(KeyAscii)) And KeyAscii <> 8 Then KeyAscii = 0 '只允许输入数字
End Sub
Private Sub Timer1_Timer() '左、下、右、上
my_Add = my_Add + 1
If my_Add = 1 Then
Call my_Swap(Image1(0), Image1(1))
ElseIf my_Add = 2 Then
Call my_Swap(Image1(0), Image1(2))
Else
Call my_Swap(Image1(0), Image1(3))
my_Add = 0
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -