1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
|
Sub creatDB()
Dim wrkDefault As Workspace
Dim dbsNew As Database
Set wrkDefault = DBEngine.Workspaces(0)
If Dir("NewDB.accdb") <> "" Then Kill "NewDB.accdb"
Set dbsNew = wrkDefault.CreateDatabase("NewDB.accdb", dbLangGeneral, dbVersion120)
dbsNew.Properties.Append dbsNew.CreateProperty("UseMDIMode", dbByte, 0)
dbsNew.Properties.Append dbsNew.CreateProperty("Themed Form Controls", dbBoolean, True)
dbsNew.Properties.Append dbsNew.CreateProperty("CheckTruncatedNumFields", dbBoolean, True)
dbsNew.Properties.Append dbsNew.CreateProperty("Picture Property Storage Format", dbLong, 0)
End Sub |
Partager