📄 frmholiday.frm
字号:
VERSION 5.00
Begin VB.Form frmHoliday
BorderStyle = 1 'Fixed Single
Caption = "假日日期"
ClientHeight = 1860
ClientLeft = 45
ClientTop = 330
ClientWidth = 4365
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1860
ScaleWidth = 4365
StartUpPosition = 1 'CenterOwner
Begin VB.CommandButton cmdCancel
Caption = "取消(&C)"
Height = 375
Left = 2880
TabIndex = 6
Top = 1320
Width = 1215
End
Begin VB.CommandButton cmdOk
Caption = "确定(&O)"
Height = 375
Left = 1440
TabIndex = 5
Top = 1320
Width = 1215
End
Begin VB.TextBox txtDay
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 1800
MaxLength = 2
TabIndex = 3
Text = "01"
Top = 600
Width = 1095
End
Begin VB.TextBox txtMonth
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 480
MaxLength = 2
TabIndex = 1
Text = "01"
Top = 600
Width = 975
End
Begin VB.Label Label3
Caption = "_"
Height = 375
Left = 1560
TabIndex = 4
Top = 585
Width = 165
End
Begin VB.Label Label2
Caption = "日期:"
Height = 255
Left = 1800
TabIndex = 2
Top = 360
Width = 495
End
Begin VB.Label Label1
Caption = "月份:"
Height = 240
Left = 480
TabIndex = 0
Top = 360
Width = 615
End
End
Attribute VB_Name = "frmHoliday"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public blAdd As Boolean
Private Sub cmdCancel_Click()
Unload frmHoliday
End Sub
Private Sub cmdOk_Click()
Dim ltmX As ListItem
If CInt(txtMonth.Text) > 12 Then
MsgBox "月份应小于12.", vbInformation, "提示"
Exit Sub
End If
If CInt(txtDay.Text) > 31 Then
MsgBox "日期应小于31.", vbInformation, "提示"
Exit Sub
End If
If blAdd = False Then
frmMain.lvDoorPeriods.SelectedItem.Text = Format(txtMonth.Text, "00") & "-" & Format(txtDay.Text, "00")
Else
Set ltmX = frmMain.lvDoorPeriods.ListItems.Add
ltmX.Text = txtMonth.Text & "-" & txtDay.Text
End If
Unload frmHoliday
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -