Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Database Container Permissions 1

Status
Not open for further replies.

scking

Programmer
Jan 8, 2001
1,263
US
I use SourceSafe to configuration manage my Access databases. SourceSafe removes all the permissions associated with groups, so before distributing the database I use a subroutine to set all the permissions for the groups against the Access objects (Queries, Tables, Forms, etc). This is not very difficult but I have been unable to determine how to set the properties for the Database object which is above the 'Tables' objects and not normally displayed when setting permissions using the Access Security Permissions forms. Below is a little snippet that uses the db.Containers!Tables.Documents.
---------------------------------------------
For Each doc In db.Containers!Tables.Documents
doc.UserName = "admins"
Select Case doc.Name
Case "tblAnyTable"
doc.Permissions = dbSecWriteSec

Does anyone know how to set the database permissions.

-------------------------------------
scking@arinc.com
Try to resolve problems independently
Then seek help among peers or experts
But TEST recommended solutions
-------------------------------------
 
I'm not sure, but it might be db.Containers!Databases.Documents("MSysDb"). Rick Sprague
To write a program from scratch, first create the universe. - Paraphrased from Albert Einstein
 
Thanks Rick! It worked. I don't know why this caused me grief because it is obvious. I should have even guessed but didn't.

-------------------------------------
scking@arinc.com
Try to resolve problems independently
Then seek help among peers or experts
But TEST recommended solutions
-------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top