Locking form fields in a protected Word template (Word 2003)

L

Lenny

I am setting up a performance review form where the supervisor selects a
rating from a dropdown and can add comments in a table cell directly below
based on the performance criteria.

There is a section for the employees responses.

Is there a way to programatically lock down the fields in the supervisor
section so the employee cannot change any of the comments or ratings?

I have section breaks dividing the various inputs into protected and
unprotected sections to allow for the use of spell check.

Best regards... Lenny
 
M

macropod

Hi Lenny,

You could use an auto macro to test the username and, if it:
.. is not the supervisor's username, the macro could turn off the "fill-in enabled" property for the supervisor-only fields.
.. is the supervisor's username, the macro could turn on the "fill-in enabled" property for the supervisor-only fields.
You'd need to have the supervisor's username hard coded or stored in the document properties.

You could also use the same technique to lock supervisors out of the employee-comment areas too. Coded correctly, only the employee
and their supervisor would be able to make any edits - others would effectively have read-only access only.

Cheers
 
L

Lenny

Hello macropod!
Could I code the 'lockdown' generically? As in thru a checkbox entry macro
and how would the code look? i.e., " [ ] Secure section here" also probably
another checkbox to unlock for edits? I love your simple solution.... and
here is the 'but'

There are way too many supervisors / employees to 'hardwire' in usernames

regards Lenny

macropod said:
Hi Lenny,

You could use an auto macro to test the username and, if it:
.. is not the supervisor's username, the macro could turn off the "fill-in enabled" property for the supervisor-only fields.
.. is the supervisor's username, the macro could turn on the "fill-in enabled" property for the supervisor-only fields.
You'd need to have the supervisor's username hard coded or stored in the document properties.

You could also use the same technique to lock supervisors out of the employee-comment areas too. Coded correctly, only the employee
and their supervisor would be able to make any edits - others would effectively have read-only access only.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
I am setting up a performance review form where the supervisor selects a
rating from a dropdown and can add comments in a table cell directly below
based on the performance criteria.

There is a section for the employees responses.

Is there a way to programatically lock down the fields in the supervisor
section so the employee cannot change any of the comments or ratings?

I have section breaks dividing the various inputs into protected and
unprotected sections to allow for the use of spell check.

Best regards... Lenny
 
M

macropod

Hi Lenny,

There is no need to code an on-entry macro for each field individually. If the auto open macro approach is taken, you could code the
form so that all fields are locked by default. That would deny access to those fields if the 'clever' user thought they could get
around things by disabling the macro. After checking the username, the macro would then automatically unlock the 'supervisor' or
'subordinate' fields, as appropriate.

Some alternatives to hard-coding the 'supervisor' usernames:
.. have the system admin maintain a text file with the 'supervisor' usernames in a location that other employees can at most get
read-only access to. Your macro would then compare the user's username against that list to determine the access level. Your
reference file doesn't need to know about all employees - only 'supervisors' (which I imagine are far fewer than 'subordinates').
.. have an auto macro pop up a dialogue box for a password. If a valid password is input, 'supervisor' access is given; otherwise
'subordinate' access is given. This way, you'd have to give all the supervisors the password, and that creates its own problems (eg
what to do if a 'subordinate' is put in a 'supervisor' position for a time, before reverting to 'subordinate').

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
Hello macropod!
Could I code the 'lockdown' generically? As in thru a checkbox entry macro
and how would the code look? i.e., " [ ] Secure section here" also probably
another checkbox to unlock for edits? I love your simple solution.... and
here is the 'but'

There are way too many supervisors / employees to 'hardwire' in usernames

regards Lenny

macropod said:
Hi Lenny,

You could use an auto macro to test the username and, if it:
.. is not the supervisor's username, the macro could turn off the "fill-in enabled" property for the supervisor-only fields.
.. is the supervisor's username, the macro could turn on the "fill-in enabled" property for the supervisor-only fields.
You'd need to have the supervisor's username hard coded or stored in the document properties.

You could also use the same technique to lock supervisors out of the employee-comment areas too. Coded correctly, only the
employee
and their supervisor would be able to make any edits - others would effectively have read-only access only.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
I am setting up a performance review form where the supervisor selects a
rating from a dropdown and can add comments in a table cell directly below
based on the performance criteria.

There is a section for the employees responses.

Is there a way to programatically lock down the fields in the supervisor
section so the employee cannot change any of the comments or ratings?

I have section breaks dividing the various inputs into protected and
unprotected sections to allow for the use of spell check.

Best regards... Lenny
 

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