form1.frm
来自「vb数据库编程资料」· FRM 代码 · 共 36 行
FRM
36 行
VERSION 5.00
Begin VB.Form Form1
Caption = "Form1"
ClientHeight = 1260
ClientLeft = 60
ClientTop = 450
ClientWidth = 3150
LinkTopic = "Form1"
ScaleHeight = 1260
ScaleWidth = 3150
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton Command1
Caption = "压缩教学数据库"
Height = 495
Left = 240
TabIndex = 0
Top = 360
Width = 2655
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Dim CurPath As String
CurPath = VB.App.Path
dbengine.CompactDatabase CurPath & "\教学.mdb", CurPath & "\Temp.mdb"
'Copy the new file over the original ·
FileCopy CurPath & "\Temp.mdb", CurPath & "\教学.mdb"
'Delete the new file
Kill CurPath & "\Temp.mdb"
End Sub
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?