Lock form design view

Leo_Polla_Psemata

Registered User.
Local time
Today, 12:35
Joined
Mar 24, 2014
Messages
364
A small problem, I need to lock the form design (Datasheet View) so that users canNOT delete controls or move controls from one place to another.
This may happen by accident.

Could I "lock" and secure the form ?
 
Generally you'd compile the application into an accde file to prevent design changes (although I think this won't prevent users from changing the column widths in a datasheet subform... in that case, you can fix them by using a continuous form and styling it to look like a datasheet instead).
 
Users should never have access to database objects. Your interface should use forms to control everything that the user sees and has access to. The database properties should hide the navigation pane (you can show it by using shift-F11. And as Jack suggested distribute the app as an .accde.

When you create an .accde, Access removes all the source code from an app and that pretty much takes care of forms and reports but it does not keep the user from mucking up any other objects. I would go a step further and rename the .accde to .accdr. Although this isn't any real protection to a developer, it will prevent people who don't know Access well from getting into design view on any object. The .accdr tells Access to pretend to be the Access runtime engine and since the runtime engine cannot open anything in design view, that achieves your purpose.

Keep in mind that EVERY user must have his own personal copy of the FE. You can easily acheive this by giving them a shortcut that runs a batch file. The batch file downloads a fresh copy of the FE from the server side backup directory. So, even if they manage to mess up their copy, the next time they open the app, their copy will be replaced by a new copy. You can set up Active directory to hide the contents of the backup directory so the users never actually see the batch file or the back up copy of the FE.

And, if you have people who continue to muck around without permission, you might want to get management to speak to them regarding what their job actually is and that tampering with company property is a firing offence.

PS - be very careful once you start creating .accde's to safeguard your original .accdb since there is no going back. If you loose the .accdb, even you will not be able to make modifications to the database design.
 

Users who are viewing this thread

Back
Top Bottom