I have a command button on a form which changes most fields from Locked to Unlocked based on the Tag.
For Each ctl In Forms![frmChangeRequests].Controls
If ctl.Tag = "LOCK" Then
ctl.Locked = False
End If
Next ctl
The code works perfectly well but I want to add to this so the same button can switch the user back to Read Only. I'm sure there is an If statement involved but I cannot for the life of me figure out how to do this.
Can anyone help me so the same button can change from RO to Update and back?
Thanks!
For Each ctl In Forms![frmChangeRequests].Controls
If ctl.Tag = "LOCK" Then
ctl.Locked = False
End If
Next ctl
The code works perfectly well but I want to add to this so the same button can switch the user back to Read Only. I'm sure there is an If statement involved but I cannot for the life of me figure out how to do this.
Can anyone help me so the same button can change from RO to Update and back?
Thanks!