?? frm開始.frm
字號:
End
Begin MySuperMarket.XButton XButton7
Height = 345
Left = 7680
TabIndex = 8
Top = 0
Width = 345
_ExtentX = 609
_ExtentY = 609
Caption = ""
ToolTip = "關于"
MouseDownColor = 16761024
MouseOnColor = 16761024
StyleColor = -2147483646
Style3dColor1 = -2147483646
Style3dColor2 = -2147483646
Picture = "frm開始.frx":250E8
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋體"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin VB.Line Line5
BorderColor = &H00A6A6A6&
X1 = 7620
X2 = 7620
Y1 = 45
Y2 = 285
End
Begin VB.Line Line4
BorderColor = &H00C0C0C0&
Visible = 0 'False
X1 = 0
X2 = 9000
Y1 = 345
Y2 = 345
End
Begin VB.Line Line1
BorderColor = &H00A6A6A6&
X1 = 585
X2 = 585
Y1 = 45
Y2 = 285
End
Begin VB.Line Line2
BorderColor = &H00A6A6A6&
X1 = 3120
X2 = 3120
Y1 = 45
Y2 = 285
End
Begin VB.Line Line3
BorderColor = &H00A6A6A6&
X1 = 5175
X2 = 5175
Y1 = 45
Y2 = 285
End
End
Begin MSComctlLib.ImageList ImageList1
Left = 1920
Top = 1440
_ExtentX = 1005
_ExtentY = 1005
BackColor = -2147483643
ImageWidth = 16
ImageHeight = 16
MaskColor = 12632256
_Version = 393216
BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628}
NumListImages = 21
BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":25682
Key = ""
EndProperty
BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":25C1C
Key = ""
EndProperty
BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":26C6E
Key = ""
EndProperty
BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":29420
Key = ""
EndProperty
BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":2C4A2
Key = ""
EndProperty
BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":2CA3C
Key = ""
EndProperty
BeginProperty ListImage7 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":2CFD6
Key = ""
EndProperty
BeginProperty ListImage8 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":2D570
Key = ""
EndProperty
BeginProperty ListImage9 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":2F6AA
Key = ""
EndProperty
BeginProperty ListImage10 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":306FC
Key = ""
EndProperty
BeginProperty ListImage11 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":33586
Key = ""
EndProperty
BeginProperty ListImage12 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":345D8
Key = ""
EndProperty
BeginProperty ListImage13 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":36D8A
Key = ""
EndProperty
BeginProperty ListImage14 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":3916C
Key = ""
EndProperty
BeginProperty ListImage15 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":3A1BE
Key = ""
EndProperty
BeginProperty ListImage16 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":3C1C0
Key = ""
EndProperty
BeginProperty ListImage17 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":3DECA
Key = ""
EndProperty
BeginProperty ListImage18 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":40F4C
Key = ""
EndProperty
BeginProperty ListImage19 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":42DCE
Key = ""
EndProperty
BeginProperty ListImage20 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":44C50
Key = ""
EndProperty
BeginProperty ListImage21 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm開始.frx":451EA
Key = ""
EndProperty
EndProperty
End
Begin XpMenuCtl.XPmenu XPmenu1
Left = 1440
Top = 2640
_ExtentX = 873
_ExtentY = 873
SelFill = 16761024
SelBorder = 8421504
DisabledSelFill = 12632256
DisabledSelBorder= 12632256
TextBack = 16777215
IcoBack = 16777088
MenuBorder = 11184810
CheckICOFill = 16744576
CheckICOSelFill = 12632256
Separator = 16744576
MainMenuHoverStart= 14466742
MainMenuHoverEnd= 14466742
IcoStart = 14466742
IcoEnd = 14466742
CheckIcoFillStart= 16744576
CheckIcoFillEnd = 16744576
CheckIcoSelFillStart= 12632256
CheckIcoSelFillEnd= 12632256
End
Begin VB.Menu ht
Caption = ""
End
Begin VB.Menu mnusys
Caption = "系統(&S)"
Begin VB.Menu mnusysyhgl
Caption = "用戶設置(&Y)"
Begin VB.Menu mnusystjyh
Caption = "用戶管理"
End
Begin VB.Menu mnusysxgmm
Caption = "修改密碼"
End
End
Begin VB.Menu ckrz
Caption = "系統日志"
End
Begin VB.Menu q
Caption = "-"
End
Begin VB.Menu mnusysquit
Caption = "退出(&X)..."
Shortcut = ^X
End
End
Begin VB.Menu mnudata
Caption = "數據維護(&D)"
Begin VB.Menu mnudataadd
Caption = "增加(&G)..."
Shortcut = ^G
End
Begin VB.Menu mnudatamodify
Caption = "修改(&X)..."
Shortcut = ^Z
End
Begin VB.Menu mnudatadelete
Caption = "刪除(&D)..."
Shortcut = ^D
End
Begin VB.Menu q5
Caption = "-"
End
Begin VB.Menu bfxjk
Caption = "數據庫備份"
Shortcut = ^{F1}
End
Begin VB.Menu hfbf
Caption = "恢復備份"
Shortcut = {F2}
End
Begin VB.Menu menuCSH
Caption = "數據初始化"
Shortcut = ^{F2}
End
End
Begin VB.Menu mnucount
Caption = "統計(&C)"
Begin VB.Menu mnucountsection
Caption = "按部門統計"
Begin VB.Menu mnucountsectionemp
Caption = "職工人數"
End
Begin VB.Menu q1
Caption = "-"
End
Begin VB.Menu mnucountsectionave
Caption = "平均工資"
End
Begin VB.Menu mnucountsectionsum
Caption = "工資總額"
End
End
Begin VB.Menu q3
Caption = "-"
End
Begin VB.Menu mnucountall
Caption = "按全體統計"
Begin VB.Menu mnucountallemp
Caption = "職工人數"
End
Begin VB.Menu q2
Caption = "-"
End
Begin VB.Menu mnucountallave
Caption = "平均工資"
End
Begin VB.Menu mnucountallsum
Caption = "工資總額"
End
End
End
Begin VB.Menu mnuquery
Caption = "查詢(&Q)"
Begin VB.Menu mnuqueryname
Caption = "按姓名查詢"
End
Begin VB.Menu q4
Caption = "-"
End
Begin VB.Menu mnuquerydepart
Caption = "按部門查詢"
End
End
Begin VB.Menu MenVal
Caption = "視圖(&V)"
Begin VB.Menu menxsgjl
Caption = "關閉工具欄"
End
Begin VB.Menu menztlxs
Caption = "狀態欄關閉"
End
End
Begin VB.Menu mnuhelp
Caption = " 幫助(&H)"
Begin VB.Menu mnuHelpAbout
Caption = "...關于(&A)..."
Shortcut = ^A
End
End
End
Attribute VB_Name = "frm開始"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'-----聲明X按鈕無效------'
Private Declare Function GetSystemMenu Lib "user32" (ByVal hwnd As Long, ByVal bRevert As Long) As Long
Private Declare Function RemoveMenu Lib "user32" ( _
ByVal hMenu As Long, ByVal nPosition As Long, _
ByVal wFlags As Long) As Long
Const MF_BYCOMMAND = &H0&
Const MF_BYPOSITION = &H400&
Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Dim btns As Integer '變量聲明
Dim b As Integer
Dim myDatabase As DATABASE
Dim myWorkspace As Workspace
Dim myTableDef As TableDef
Dim myField(8) As Field
Private Sub Menu()
Dim a As Menu
Set a = mnusys
Dim d As Collection
Call XPmenu1.AddMenuPicture("用戶設置(&Y)", ImageList1.ListImages(1).Picture)
Call XPmenu1.AddMenuPicture("用戶管理", ImageList1.ListImages(2).Picture)
Call XPmenu1.AddMenuPicture("修改密碼", ImageList1.ListImages(3).Picture)
Call XPmenu1.AddMenuPicture("系統日志", ImageList1.ListImages(4).Picture)
Call XPmenu1.AddMenuPicture("退出(&X)...", ImageList1.ListImages(5).Picture)
Call XPmenu1.AddMenuPicture("增加(&G)...", ImageList1.ListImages(6).Picture)
Call XPmenu1.AddMenuPicture("修改(&X)...", ImageList1.ListImages(7).Picture)
Call XPmenu1.AddMenuPicture("刪除(&D)...", ImageList1.ListImages(8).Picture)
Call XPmenu1.AddMenuPicture("數據庫備份", ImageList1.ListImages(9).Picture)
Call XPmenu1.AddMenuPicture("恢復備份", ImageList1.ListImages(10).Picture)
Call XPmenu1.AddMenuPicture("數據初始化", ImageList1.ListImages(21).Picture)
Call XPmenu1.AddMenuPicture("按部門統計", ImageList1.ListImages(11).Picture)
Call XPmenu1.AddMenuPicture("職工人數", ImageList1.ListImages(12).Picture)
Call XPmenu1.AddMenuPicture("平均工資", ImageList1.ListImages(13).Picture)
Call XPmenu1.AddMenuPicture("工資總額", ImageList1.ListImages(14).Picture)
Call XPmenu1.AddMenuPicture("按全體統計", ImageList1.ListImages(15).Picture)
Call XPmenu1.AddMenuPicture("按姓名查詢", ImageList1.ListImages(16).Picture)
Call XPmenu1.AddMenuPicture("按部門查詢", ImageList1.ListImages(17).Picture)
Call XPmenu1.AddMenuPicture("關閉工具欄", ImageList1.ListImages(18).Picture)
Call XPmenu1.AddMenuPicture("狀態欄關閉", ImageList1.ListImages(19).Picture)
Call XPmenu1.AddMenuPicture("顯示工具欄", ImageList1.ListImages(18).Picture)
Call XPmenu1.AddMenuPicture("狀態欄顯示", ImageList1.ListImages(19).Picture)
Call XPmenu1.AddMenuPicture("...關于(&A)...", ImageList1.ListImages(20).Picture)
End Sub
Private Sub bfxjk_Click()
Dim mfile As String, mfile2 As String
'Dim buff() As Byte
'Dim i As Long
On Error Resume Next
MkDir App.Path + "\Backup"
mfile = App.Path & "\data\職工工資管理.mdb"
mfile2 = App.Path & "\Backup\$Back%.inf"
If Trim(mfile2) = "" Then Exit Sub
If Dir(mfile2) <> "" Then
If MsgBox(Dir(mfile2) & " 文件已經存在,是否替換?", vbYesNo, "警告") = vbNo Then Exit Sub
End If
Dim buff() As Byte, i As Long
i = FileLen(mfile)
ReDim buff(i - 1)
Open mfile For Binary As #1
Get #1, , buff
Close #1
Open mfile2 For Binary As #1
Put #1, , buff
Close #1
MsgBox "備份完畢!"
'添加系統日志信息
MyLog.Title = "成員:備份當前數據庫記錄"
MyLog.Body = "數據備份"
MyLog.LogType = "數據備份"
MyLog.UserName = CurUser.name
MyLog.Save
End Sub
Private Sub hfbf_Click()
Dim mfile As String, mfile2 As String
Dim buff() As Byte
Dim i As Long
On Error Resume Next
mfile = App.Path + "\Backup\$Back%.inf"
mfile2 = App.Path + "\data\職工工資管理.mdb"
If Dir(mfile) = "" Then
MsgBox "沒有發現可以恢復的數據庫!", vbOKOnly + vbCritical, "警告"
RmDir App.Path + "\Backup"
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -