In my application I create Jet dbs on the fly and subsequently add the necessary fields. Although I use predominantly ADO for my coding, I use DAO to create the db with no problems, as indicated below,
Set db = DBEngine.CreateDatabase(DBFullPath, dbLangGeneral)
I have 2 questions:
1) Can I add a password to the db created with DAO?
2) Can I use ADOX to create the dB? I tried using the following
Dim cat As New ADOX.Catalog
Dim strFile As String
cat.Create "Provider='Microsoft.Jet.OLEDB.4.0';" & _
"Data Source='" & strFile & "'"
Set cat = Nothing
It creates the db, but when I try to open the db by clicking on the db file, it tells me
"Record(s) cannot be read; no read permission on 'MSysObjects' ". Apparently I have no read permission.
I used ADOX in the past and it proved unstable and version dependent.
Essentially, I would like to create on the fly a password-protected database and be able to add/delete fields and data. Any ideas?
Thanks,
John
Set db = DBEngine.CreateDatabase(DBFullPath, dbLangGeneral)
I have 2 questions:
1) Can I add a password to the db created with DAO?
2) Can I use ADOX to create the dB? I tried using the following
Dim cat As New ADOX.Catalog
Dim strFile As String
cat.Create "Provider='Microsoft.Jet.OLEDB.4.0';" & _
"Data Source='" & strFile & "'"
Set cat = Nothing
It creates the db, but when I try to open the db by clicking on the db file, it tells me
"Record(s) cannot be read; no read permission on 'MSysObjects' ". Apparently I have no read permission.
I used ADOX in the past and it proved unstable and version dependent.
Essentially, I would like to create on the fly a password-protected database and be able to add/delete fields and data. Any ideas?
Thanks,
John