📄 frmgetdate.frm
字号:
VERSION 5.00
Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomct2.ocx"
Begin VB.Form frmGetDate
BorderStyle = 3 'Fixed Dialog
Caption = "请选择日期"
ClientHeight = 3090
ClientLeft = 2760
ClientTop = 3750
ClientWidth = 4200
LinkTopic = "Form1"
LockControls = -1 'True
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 3090
ScaleWidth = 4200
ShowInTaskbar = 0 'False
Begin MSComCtl2.MonthView mvDate
Height = 2220
Left = 60
TabIndex = 2
Top = 60
Width = 4065
_ExtentX = 7170
_ExtentY = 3916
_Version = 393216
ForeColor = -2147483630
BackColor = -2147483633
Appearance = 1
StartOfWeek = 25427969
CurrentDate = 38465
End
Begin VB.CommandButton CancelButton
Caption = "取消[&C]"
Height = 375
Left = 2850
TabIndex = 1
Top = 2580
Width = 1215
End
Begin VB.CommandButton OKButton
Caption = "确定[&O]"
Height = 375
Left = 1410
TabIndex = 0
Top = 2595
Width = 1215
End
End
Attribute VB_Name = "frmGetDate"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Public SelectDate As String
Private Sub CancelButton_Click()
SelectDate = ""
Me.Hide
End Sub
Private Sub Form_Load()
SelectDate = ""
End Sub
Private Sub OKButton_Click()
If IsDate(mvDate.value) Then
SelectDate = FormatDateTime(mvDate.value, vbShortDate)
Else
SelectDate = ""
End If
Me.Hide
End Sub
Public Function setDate(thedate As String) As Boolean
setDate = IsDate(thedate)
If setDate = True Then
mvDate.value = CDate(thedate)
End If
End Function
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -