?? frmbackup.frm
字號:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Begin VB.Form frmBackup
BorderStyle = 1 'Fixed Single
Caption = "數據恢復"
ClientHeight = 2310
ClientLeft = 5100
ClientTop = 5325
ClientWidth = 5400
LinkTopic = "Form3"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 2310
ScaleWidth = 5400
Begin VB.PictureBox Picture1
AutoSize = -1 'True
BorderStyle = 0 'None
Height = 720
Left = 480
Picture = "frmBackup.frx":0000
ScaleHeight = 720
ScaleWidth = 720
TabIndex = 4
Top = 240
Width = 720
End
Begin MSComctlLib.ProgressBar ProgressBar1
Height = 195
Left = 360
TabIndex = 3
Top = 1920
Visible = 0 'False
Width = 4575
_ExtentX = 8070
_ExtentY = 344
_Version = 393216
Appearance = 1
End
Begin VB.CommandButton Command2
Caption = "退出"
Height = 495
Left = 3240
TabIndex = 2
Top = 1200
Width = 1215
End
Begin VB.CommandButton Command1
Caption = "恢復"
Height = 495
Left = 1080
TabIndex = 1
Top = 1200
Width = 1215
End
Begin VB.Label Label1
Height = 495
Left = 2040
TabIndex = 0
Top = 480
Width = 1215
End
End
Attribute VB_Name = "frmBackup"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'調用Windows API函數,函數聲明
Private Declare Function CopyFile Lib "kernel32" Alias "CopyFileA" (ByVal lpExistingFileName As String, ByVal lpNewFileName As String, ByVal bFailIfExists As Long) As Long
Private Sub Command1_Click()
ProgressBar1.Min = 0 '設置最小值
ProgressBar1.Max = 100 '設置最大值
ProgressBar1.Value = 100 '當前進度值
CopyFile "數據備份.mdb", "水電費管理系統數據庫.mdb", 0
ProgressBar1.Visible = True
Label1.Caption = "數據恢復成功!"
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Form_Load()
path1 = App.Path & "\水電費管理系統數據庫.mdb"
path2 = App.Path & "\數據備份.mdb"
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -