JeffCarlin
Programmer
This code is taken straight from MSDN. However, when it tries to execute the Append method into an Access XP database, I get "Err 3251, Object or provider is not capable of performing requested operation.":
Anyone have an idea??
Code:
Dim cat As ADOX.Catalog
Dim usrNew As ADOX.User
Set cat = New ADOX.Catalog
cat.ActiveConnection = "Provider=MICROSOFT.JET.OLEDB.4.0;" _
& "Jet OLEDB:System database=mySystem.mdw;" _
& "User ID=admin;" _
& "Password=admin;" _
& "Persist Security Info=True;" _
& "Data Source=myDB.mdb"
With cat
' Create and append new user with an object.
Set usrNew = New ADOX.User
usrNew.Name = "PatSmith"
usrNew.ChangePassword "", "password1"
.Users.Append usrNew
End With