MS Access: how to compact current database in VBA

后端 未结 13 1629
慢半拍i
慢半拍i 2020-11-29 07:34

Pretty simple question, I know.

13条回答
  •  长情又很酷
    2020-11-29 07:57

    Check out this solution VBA Compact Current Database.

    Basically it says this should work

    Public Sub CompactDB() 
        CommandBars("Menu Bar").Controls("Tools").Controls ("Database utilities"). _
        Controls("Compact and repair database...").accDoDefaultAction 
    End Sub 
    

提交回复
热议问题