📄 dialog.frm
字号:
VERSION 5.00
Begin VB.Form Dialog
BorderStyle = 3 'Fixed Dialog
Caption = "Dialog Caption"
ClientHeight = 3270
ClientLeft = 2760
ClientTop = 3750
ClientWidth = 2880
ControlBox = 0 'False
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 3270
ScaleWidth = 2880
ShowInTaskbar = 0 'False
Begin VB.CommandButton CancelButton
Caption = "Cancel"
Height = 375
Left = 1560
TabIndex = 7
Top = 2520
Width = 975
End
Begin VB.TextBox Text3
Alignment = 1 'Right Justify
BackColor = &H80000016&
Height = 375
Left = 1320
Locked = -1 'True
TabIndex = 6
Top = 360
Width = 1095
End
Begin VB.TextBox Text2
Alignment = 1 'Right Justify
Height = 375
Left = 1320
MaxLength = 2
TabIndex = 2
Text = "0"
Top = 1800
Width = 1095
End
Begin VB.TextBox Text1
Alignment = 1 'Right Justify
Height = 375
Left = 1320
MaxLength = 2
TabIndex = 1
Text = "0"
Top = 1080
Width = 1095
End
Begin VB.CommandButton OKButton
Caption = "OK"
Height = 375
Left = 360
TabIndex = 0
Top = 2520
Width = 975
End
Begin VB.Label Label3
Caption = "Process ID:"
Height = 375
Left = 240
TabIndex = 5
Top = 360
Width = 855
End
Begin VB.Label Label2
Caption = "Burst Time:"
Height = 375
Left = 240
TabIndex = 4
Top = 1080
Width = 855
End
Begin VB.Label Label1
Caption = "Arrival Time:"
Height = 375
Left = 240
TabIndex = 3
Top = 1800
Width = 975
End
End
Attribute VB_Name = "Dialog"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub CancelButton_Click()
TotalProcess = TotalProcess - 1
Unload Dialog
End Sub
Private Sub Form_Load()
TotalProcess = TotalProcess + 1
Text3.Text = "P" & TotalProcess
End Sub
Private Sub OKButton_Click()
If (Text1.Text <> "0" And Text1.Text <> "") Then
Proc(TotalProcess - 1).ProcessID = Text3.Text
Proc(TotalProcess - 1).BurstTime = Text1.Text
Proc(TotalProcess - 1).ArrivalTime = Text2.Text
Proc(TotalProcess - 1).RemainTime = Text1.Text
Unload Dialog
Else
MsgBox "Invalid Burst time value"
End If
End Sub
Private Sub Text1_Change()
If Not IsNumeric(Text1.Text) Then
Text1.Text = ""
End If
End Sub
Private Sub Text2_Change()
If Not IsNumeric(Text2.Text) Then
Text2.Text = ""
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -