frmMain.frm
上传用户:yexiandon
上传日期:2022-07-12
资源大小:895k
文件大小:13k
- 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"
- Object = "{74238AF8-8108-44A9-B3DE-D652F61AB8DC}#2.3#0"; "yfDNetMenu.ocx"
- Begin VB.MDIForm frmMain
- BackColor = &H8000000C&
- ClientHeight = 5685
- ClientLeft = 165
- ClientTop = 450
- ClientWidth = 9555
- Icon = "frmMain.frx":0000
- LinkTopic = "MDIForm1"
- NegotiateToolbars= 0 'False
- StartUpPosition = 1 '所有者中心
- WindowState = 2 'Maximized
- Begin MSComctlLib.StatusBar sbStatusBar
- Align = 2 'Align Bottom
- Height = 390
- Left = 0
- TabIndex = 0
- Top = 5295
- Width = 9555
- _ExtentX = 16854
- _ExtentY = 688
- _Version = 393216
- BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628}
- NumPanels = 5
- BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628}
- AutoSize = 1
- Object.Width = 2752
- Text = "状态"
- TextSave = "状态"
- EndProperty
- BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628}
- Object.Width = 4939
- MinWidth = 4939
- Picture = "frmMain.frx":08CA
- EndProperty
- BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628}
- Object.Width = 4057
- MinWidth = 4057
- Picture = "frmMain.frx":11A4
- EndProperty
- BeginProperty Panel4 {8E3867AB-8586-11D1-B16A-00C0F0283628}
- Style = 6
- AutoSize = 2
- TextSave = "2008-01-21"
- EndProperty
- BeginProperty Panel5 {8E3867AB-8586-11D1-B16A-00C0F0283628}
- Style = 5
- AutoSize = 2
- Object.Width = 1931
- MinWidth = 1940
- TextSave = "15:55"
- EndProperty
- EndProperty
- End
- Begin MSComDlg.CommonDialog dlgCommonDialog
- Left = 1200
- Top = 1800
- _ExtentX = 847
- _ExtentY = 847
- _Version = 393216
- End
- Begin yfDNetMenu.DNetMenu DNetMenu1
- Left = 1800
- Top = 1800
- _ExtentX = 847
- _ExtentY = 847
- BmpCount = 7
- Bmp:1 = "frmMain.frx":14BE
- Key:1 = "#mnuFileExit"
- Bmp:2 = "frmMain.frx":18E6
- Mask:2 = -32768
- Key:2 = "#mnuExportWage"
- Bmp:3 = "frmMain.frx":1D0E
- Key:3 = "#mnuChang"
- Bmp:4 = "frmMain.frx":2A76
- Key:4 = "#mnuViewWebBrowser"
- Bmp:5 = "frmMain.frx":2E9E
- Key:5 = "#mnuHelpContents"
- Bmp:6 = "frmMain.frx":32C6
- Key:6 = "#mnuChangePass"
- Bmp:7 = "frmMain.frx":36EE
- Key:7 = "#mnuFileSave"
- BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
- Name = "Tahoma"
- Size = 8.25
- Charset = 0
- Weight = 400
- Underline = 0 'False
- Italic = 0 'False
- Strikethrough = 0 'False
- EndProperty
- End
- Begin VB.Menu mnuSystem
- Caption = "系统(&S)"
- Begin VB.Menu mnuChang
- Caption = "重新登陆(&C)"
- End
- Begin VB.Menu mnuChangePass
- Caption = "更改密码(&P)"
- End
- Begin VB.Menu mnuUsers
- Caption = "用户管理(&U)"
- Enabled = 0 'False
- End
- Begin VB.Menu mnuFileBar1
- Caption = "-"
- End
- Begin VB.Menu mnuFileExit
- Caption = "退出(&X)"
- End
- End
- Begin VB.Menu mnuTools
- Caption = "工具(&T)"
- Begin VB.Menu mnuFileOpen
- Caption = "引入(&I)..."
- End
- Begin VB.Menu mnuExport
- Caption = "引出(&E)..."
- End
- Begin VB.Menu mnuFileBar5
- Caption = "-"
- End
- Begin VB.Menu mnuCalc
- Caption = "计算器(&C)"
- End
- End
- Begin VB.Menu mnuO
- Caption = "操作(&O)"
- Begin VB.Menu mnuEmpolee
- Caption = "职员基本信息"
- End
- Begin VB.Menu mnuCilent
- Caption = "前台客户管理"
- End
- Begin VB.Menu mnuBar4
- Caption = "-"
- End
- Begin VB.Menu mnuDsbj
- Caption = "定损报件单"
- End
- Begin VB.Menu mnuBuy
- Caption = "配件采购单"
- End
- Begin VB.Menu mnuBar3
- Caption = "-"
- End
- Begin VB.Menu mnuUsePJ
- Caption = "维修用配件"
- End
- Begin VB.Menu mnuRepairHour
- Caption = "维修用工时"
- End
- Begin VB.Menu mnuCg
- Caption = "采购"
- Visible = 0 'False
- Begin VB.Menu mnuNewCg
- Caption = "新增采购单"
- End
- Begin VB.Menu mnuEditCg
- Caption = "修改采购单"
- End
- Begin VB.Menu mnuDelCg
- Caption = "删除采购单"
- End
- Begin VB.Menu mnuViewCg
- Caption = "查看采购单"
- End
- End
- Begin VB.Menu mnuLy
- Caption = "领用"
- Visible = 0 'False
- Begin VB.Menu mnuNewLy
- Caption = "新增领用单"
- End
- Begin VB.Menu mnuEditLy
- Caption = "修改领用单"
- End
- Begin VB.Menu mnuDelLy
- Caption = "删除领用单"
- End
- Begin VB.Menu mnuViewLy
- Caption = "查看领用单"
- End
- End
- End
- Begin VB.Menu mnuSerch
- Caption = "查询(&S)"
- Begin VB.Menu mnuSerchCg
- Caption = "采购查询"
- End
- Begin VB.Menu mnuSerchClient
- Caption = "客户查询"
- End
- End
- Begin VB.Menu mnuView
- Caption = "视图(&V)"
- Begin VB.Menu mnuViewStatusBar
- Caption = "状态栏(&B)"
- Checked = -1 'True
- End
- Begin VB.Menu mnuWindow
- Caption = "窗口(&W)"
- WindowList = -1 'True
- Begin VB.Menu mnuWindowCascade
- Caption = "层叠(&C)"
- End
- Begin VB.Menu mnuWindowTileHorizontal
- Caption = "横向平铺(&H)"
- End
- Begin VB.Menu mnuWindowTileVertical
- Caption = "纵向平铺(&V)"
- End
- Begin VB.Menu mnuWindowArrangeIcons
- Caption = "排列图标(&A)"
- End
- End
- Begin VB.Menu mnuViewBar0
- Caption = "-"
- End
- Begin VB.Menu mnuViewOptions
- Caption = "选项(&O)..."
- End
- End
- Begin VB.Menu mnuHelp
- Caption = "帮助(&H)"
- Begin VB.Menu mnuHelpContents
- Caption = "目录(&C)"
- End
- Begin VB.Menu mnuHelpSearchForHelpOn
- Caption = "搜索帮助主题(&S)..."
- End
- Begin VB.Menu mnuHelpBar0
- Caption = "-"
- End
- Begin VB.Menu mnuViewWebBrowser
- Caption = "公司主页(&W)"
- End
- Begin VB.Menu mnuHelpAbout
- Caption = "关于(&A) "
- End
- End
- End
- Attribute VB_Name = "frmMain"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- '****************************************************************************
- '人人为我,我为人人
- '枕善居收藏整理
- '发布日期:2008/01/21
- '描 述:汽车维修管理系统SQL2000版
- '网 站:http://www.Mndsoft.com/ (VB6源码博客)
- '网 站:http://www.VbDnet.com/ (VB.NET源码博客,主要基于.NET2005)
- 'e-mail :Mndsoft@163.com
- 'e-mail :Mndsoft@126.com
- 'OICQ :88382850
- ' 如果您有新的好的代码别忘记给枕善居哦!
- '****************************************************************************
- Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Any) As Long
- Const EM_UNDO = &HC7
- Private Declare Function OSWinHelp% Lib "user32" Alias "WinHelpA" (ByVal hwnd&, ByVal HelpFile$, ByVal wCommand%, dwData As Any)
- Private Sub MDIForm_Activate()
- Me.sbStatusBar.Panels(2) = "帐套: " & g_ACCname
- Me.sbStatusBar.Panels(3) = "操作员: " & g_Admin
- If g_Conn.State <> 1 Then MsgBox "数据库连接失败!": End
- If IsSys(g_Admin) Then mnuUsers.Enabled = True Else mnuUsers.Enabled = False
- End Sub
- 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)
- Me.Caption = App.Title
- 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
- For i = Forms.Count - 1 To 1 Step -1
- Unload Forms(i)
- Next
- End Sub
- Private Sub mnuBuy_Click()
- frmCg.Show
- End Sub
- Private Sub mnuCalc_Click()
- Shell App.Path & "calc.exe", vbNormalFocus
- End Sub
- Private Sub mnuChang_Click()
- frmLogin.Show vbModal
- End Sub
- Private Sub mnuChangePass_Click()
- frmChangPass.Show vbModal
- End Sub
- Private Sub mnuCilent_Click()
- frmCilent.Show
- End Sub
- Private Sub mnuDepartment_Click()
- End Sub
- Private Sub mnuDsbj_Click()
- frmPJ.Show
- End Sub
- Private Sub mnuEmpolee_Click()
- frmBase.Show
- End Sub
- Private Sub mnuHelpAbout_Click()
- frmAbout.Show vbModal, Me
- End Sub
- Private Sub mnuHelpSearchForHelpOn_Click()
- Dim nRet As Integer
- '如果这个工程没有帮助文件,显示消息给用户
- '可以在“工程属性”对话框中为应用程序设置帮助文件
- If Len(App.HelpFile) = 0 Then
- MsgBox "无法显示帮助目录,该工程没有相关联的帮助。", vbInformation, Me.Caption
- Else
- On Error Resume Next
- nRet = OSWinHelp(Me.hwnd, App.HelpFile, 261, 0)
- If Err Then
- MsgBox Err.Description
- End If
- End If
- End Sub
- Private Sub mnuHelpContents_Click()
- Dim nRet As Integer
- '如果这个工程没有帮助文件,显示消息给用户
- '可以在“工程属性”对话框中为应用程序设置帮助文件
- If Len(App.HelpFile) = 0 Then
- MsgBox "无法显示帮助目录,该工程没有相关联的帮助。", vbInformation, Me.Caption
- Else
- On Error Resume Next
- nRet = OSWinHelp(Me.hwnd, App.HelpFile, 3, 0)
- If Err Then
- MsgBox Err.Description
- End If
- End If
- End Sub
- Private Sub mnuRepairPJ_Click()
- frmDataList.Show
- End Sub
- Private Sub mnuRepairHour_Click()
- frmGS.Show
- End Sub
- Private Sub mnuSerchCg_Click()
- frmDataList.Show
- End Sub
- Private Sub mnuUsePJ_Click()
- frmUse.Show
- End Sub
- Private Sub mnuUsers_Click()
- frmSq.Show vbModal
- 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 mnuViewWebBrowser_Click()
- Shell "explorer.exe http://www.lnzhqy.com/"
- End Sub
- Private Sub mnuViewStatusBar_Click()
- mnuViewStatusBar.Checked = Not mnuViewStatusBar.Checked
- sbStatusBar.Visible = mnuViewStatusBar.Checked
- End Sub
- Private Sub mnuFileExit_Click()
- '卸载窗体
- Unload Me
- End
- End Sub
- Private Sub mnuFileOpen_Click()
- Dim sFile As String
- With dlgCommonDialog
- .DialogTitle = "打开"
- .CancelError = False
- 'ToDo: 设置 common dialog 控件的标志和属性
- .Filter = "所有文件 (*.*)|*.*"
- .ShowOpen
- If Len(.FileName) = 0 Then
- Exit Sub
- End If
- sFile = .FileName
- End With
- End Sub