How do I make an Access table read only?

W

Wayne Brady

I have a table that should not be changed. I would like to make the table
read only so that a person entering data into the database would not be able
to modify that table without a password.

I would appreciate any help you can provide.

Thank you.

Wayne
 
D

Daniel Pineault

Wayne,

Your user's should never be accessing tables directly! If they are then you
need to reevaluate your db design.

That said, there is no way to password protect a table persay.

There are way you could approach this.

1. Hide the table so it does not appear in the default object list.
2. Implement Security and remove the perms to your user's

Take a look at :
http://en.allexperts.com/q/Using-MS-Access-1440/Password-protect-table.htm
http://www.access-programmers.co.uk/forums/archive/index.php/t-77512.html

In all cases, I would recommend only accessing data through forms. If you
do this then you can easily set it up so your user can use the info from
tables but not modify it. If necessary you could take it to the next level
and implement Security, but just basic forms would allow you the level of
control you seek.
--
Hope this helps,

Daniel Pineault
http://www.cardaconsultants.com/
For Access Tips and Examples: http://www.devhut.net
Please rate this post using the vote buttons if it was helpful.
 
J

Jeff Boyce

Wayne

Do you mean the table's structure, or the table's contents?

I agree with Daniel P -- your users should never see (nor have to see) the
table structure. Access is not a spreadsheet!

And you CAN control how users see the data by, as Daniel mentions, using
forms.

Another approach would be to use a query to return the data in the table to
a form, but disallow changes via the form. Then, if your user entered a
(valid) password, you could use code to re-allow changes via the form.

Regards

Jeff Boyce
Microsoft Access MVP

--
Disclaimer: This author may have received products and services mentioned
in this post. Mention and/or description of a product or service herein
does not constitute endorsement thereof.

Any code or psuedocode included in this post is offered "as is", with no
guarantee as to suitability.

You can thank the FTC of the USA for making this disclaimer
possible/necessary.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top