📄 frmmain.frm
字号:
VERSION 5.00
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomctl.ocx"
Begin VB.MDIForm frmMain
BackColor = &H8000000C&
Caption = "酒店客房信息管理系统"
ClientHeight = 6285
ClientLeft = 165
ClientTop = 780
ClientWidth = 11910
LinkTopic = "MDIForm1"
StartUpPosition = 3 '窗口缺省
Begin MSComctlLib.Toolbar tbToolBar
Align = 1 'Align Top
Height = 960
Left = 0
TabIndex = 1
Top = 0
Width = 11910
_ExtentX = 21008
_ExtentY = 1693
ButtonWidth = 1984
ButtonHeight = 1535
Appearance = 1
ImageList = "imlToolbarIcons"
_Version = 393216
BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628}
NumButtons = 12
BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Quit"
ImageIndex = 1
EndProperty
BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628}
Style = 3
EndProperty
BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "AddRoom"
ImageIndex = 2
EndProperty
BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Search"
ImageIndex = 3
EndProperty
BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628}
Style = 3
EndProperty
BeginProperty Button6 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Operator"
ImageIndex = 4
EndProperty
BeginProperty Button7 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "CodeMaintain"
ImageIndex = 5
EndProperty
BeginProperty Button8 {66833FEA-8583-11D1-B16A-00C0F0283628}
Style = 3
EndProperty
BeginProperty Button9 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Cascade"
ImageIndex = 6
EndProperty
BeginProperty Button10 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Horizon"
ImageIndex = 7
EndProperty
BeginProperty Button11 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Vertical"
ImageIndex = 8
EndProperty
BeginProperty Button12 {66833FEA-8583-11D1-B16A-00C0F0283628}
Key = "Help"
ImageIndex = 9
EndProperty
EndProperty
End
Begin MSComctlLib.StatusBar sbStatusBar
Align = 2 'Align Bottom
Height = 270
Left = 0
TabIndex = 0
Top = 6015
Width = 11910
_ExtentX = 21008
_ExtentY = 476
_Version = 393216
BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628}
NumPanels = 3
BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628}
AutoSize = 1
Object.Width = 15319
Text = "Status"
TextSave = "Status"
EndProperty
BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628}
Style = 6
AutoSize = 2
TextSave = "2008-8-5"
EndProperty
BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628}
Style = 5
AutoSize = 2
TextSave = "17:40"
EndProperty
EndProperty
End
Begin MSComDlg.CommonDialog dlgCommonDialog
Left = 840
Top = 1800
_ExtentX = 847
_ExtentY = 847
_Version = 393216
End
Begin MSComctlLib.ImageList imlToolbarIcons
Left = 120
Top = 1440
_ExtentX = 1005
_ExtentY = 1005
BackColor = -2147483643
ImageWidth = 68
ImageHeight = 52
MaskColor = 12632256
_Version = 393216
BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628}
NumListImages = 10
BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":0000
Key = "Quit"
EndProperty
BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":06C6
Key = "AddRoom"
EndProperty
BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":1058
Key = "Search"
EndProperty
BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":18C6
Key = "Operator"
EndProperty
BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":2068
Key = "CodeMaintain"
EndProperty
BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":2895
Key = "Cascade"
EndProperty
BeginProperty ListImage7 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":325E
Key = "Horizon"
EndProperty
BeginProperty ListImage8 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":3C18
Key = "Vertical"
EndProperty
BeginProperty ListImage9 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":45D5
Key = "Help"
EndProperty
BeginProperty ListImage10 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmMain.frx":4E8F
Key = ""
EndProperty
EndProperty
End
Begin VB.Menu mnuSys
Caption = "系统(&S)"
Begin VB.Menu mnuSysQuit
Caption = "退出"
End
End
Begin VB.Menu mnuRoom
Caption = "客房管理(&R)"
Begin VB.Menu mnuRoomAddRoom
Caption = "增加客房"
Shortcut = {F2}
End
Begin VB.Menu mnuRoomSearch
Caption = "查询修改"
Shortcut = {F3}
End
Begin VB.Menu mnuRoomMag
Caption = "客房管理"
Shortcut = {F4}
End
End
Begin VB.Menu mnuCustomMag
Caption = "客户管理(&C)"
Begin VB.Menu mnuCustomAddCustom
Caption = "添加客户"
End
Begin VB.Menu mnuCustomSearch
Caption = "查询"
End
End
Begin VB.Menu mnuOptions
Caption = "辅助管理(&O)"
Begin VB.Menu mnuOptionsOperator
Caption = "操作员管理"
Shortcut = {F5}
End
Begin VB.Menu mnuOptionsCodeMaintain
Caption = "代码维护"
Shortcut = {F6}
End
End
Begin VB.Menu mnuWindow
Caption = "&窗口"
WindowList = -1 'True
Begin VB.Menu mnuWindowCascade
Caption = "级联层叠"
End
Begin VB.Menu mnuWindowTileHorizontal
Caption = "水平平铺"
End
Begin VB.Menu mnuWindowTileVertical
Caption = "垂直平铺"
End
Begin VB.Menu mnuWindowNewWindow
Caption = "新窗口"
End
End
Begin VB.Menu mnuHelp
Caption = "&帮助"
Begin VB.Menu mnuHelpAbout
Caption = "关于"
Shortcut = {F1}
End
End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Declare Function OSWinHelp% Lib "user32" Alias "WinHelpA" (ByVal hwnd&, ByVal HelpFile$, ByVal wCommand%, dwData As Any)
Private Sub MDIForm_Load()
Me.Left = GetSetting(App.Title, "Settings", "MainLeft", 1000)
Me.Top = GetSetting(App.Title, "Settings", "MainTop", 1000)
Me.Width = GetSetting(App.Title, "Settings", "MainWidth", 6500)
Me.Height = GetSetting(App.Title, "Settings", "MainHeight", 6500)
LoadNewDoc
'frmRoomManage.Show vbModal
End Sub
Private Sub LoadNewDoc() '创建一个新窗口的子函数
Static lDocumentCount As Long
Dim frmD As frmDocument
lDocumentCount = lDocumentCount + 1
Set frmD = New frmDocument
frmD.Caption = "Document " & lDocumentCount
frmD.Show
End Sub
Private Sub MDIForm_Unload(Cancel As Integer)
If Me.WindowState <> vbMinimized Then
SaveSetting App.Title, "Settings", "MainLeft", Me.Left
SaveSetting App.Title, "Settings", "MainTop", Me.Top
SaveSetting App.Title, "Settings", "MainWidth", Me.Width
SaveSetting App.Title, "Settings", "MainHeight", Me.Height
End If
End Sub
Private Sub mnuCustomAddCustom_Click()
frmAddCustom.Show
End Sub
Private Sub mnuCustomSearch_Click()
frmCustomSearch.Show
End Sub
Private Sub mnuOptionsCodeMaintain_Click()
frmCodeTableEdit.Show
End Sub
Private Sub mnuOptionsOperator_Click()
frmOperatorMag.Show
End Sub
Private Sub mnuRoomAddRoom_Click()
frmAddRoom.Show
End Sub
Private Sub mnuRoomMag_Click()
frmRoomManage.Show
End Sub
Private Sub mnuRoomSearch_Click()
frmRoomSearch.Show
End Sub
Private Sub mnuSysQuit_Click()
Unload Me
End Sub
Private Sub tbToolBar_ButtonClick(ByVal Button As MSComCtlLib.Button)
On Error Resume Next
' 以下是修改的代码,用于响应工具栏上的按钮
' 其中的各个窗体模块将在后面继续创建
Select Case Button.Key
Case "Quit"
Unload Me
Exit Sub
Case "AddRoom"
frmAddRoom.Show
Exit Sub
Case "Search"
frmRoomSearch.Show
Exit Sub
Case "Report"
frmStaticReport.Show
Exit Sub
Case "Operator"
frmOperatorMag.Show
Exit Sub
Case "CodeMaintain"
frmCodeTableEdit.Show
Exit Sub
Case "Cascade"
Me.Arrange vbCascade
Exit Sub
Case "Horizon"
Me.Arrange vbHorizontal
Exit Sub
Case "Vertical"
Me.Arrange vbVertical
Exit Sub
Case "Help"
frmAbout.Show
End Select
End Sub
Private Sub mnuHelpAbout_Click() '关于
frmAbout.Show vbModal, Me
End Sub
Private Sub mnuWindowArrangeIcons_Click()
Me.Arrange vbArrangeIcons
End Sub
Private Sub mnuWindowTileVertical_Click() '垂直平铺
Me.Arrange vbTileVertical
End Sub
Private Sub mnuWindowTileHorizontal_Click() '水平平铺
Me.Arrange vbTileHorizontal
End Sub
Private Sub mnuWindowCascade_Click() '级联层叠
Me.Arrange vbCascade
End Sub
Private Sub mnuWindowNewWindow_Click() '新窗口
LoadNewDoc
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -