A
Annette
I have an approved field on a form, that once a name is populated in
the approved field I would like to turn off allowedits and
allowdeletions.
I was using this code:
With Me
.AllowEdits = (Me.ApprovedByID = 1)
.AllowDeletions = Me.AllowEdits
Me.frmTimeDetail.Enabled = Me.AllowEdits
Me.frmTimeDetail.Locked = Not Me.AllowEdits
End With
So, if I entered an ApprovedByID other than 1, I expected the form to
not allow for edits or deletes. This was not true. I could still
change other fields on the form (with the exception of the
frmTimeDetail) subform. Once I exited the record and came back to the
form, sure enough I could not change the fields. How can I make that
happen sooner -- do I need to issue a save to get it to take effect?
Any other suggestions to do this process? Basically, if someone
approves the time record, I do not want it to ever get changed.
Thanks!
the approved field I would like to turn off allowedits and
allowdeletions.
I was using this code:
With Me
.AllowEdits = (Me.ApprovedByID = 1)
.AllowDeletions = Me.AllowEdits
Me.frmTimeDetail.Enabled = Me.AllowEdits
Me.frmTimeDetail.Locked = Not Me.AllowEdits
End With
So, if I entered an ApprovedByID other than 1, I expected the form to
not allow for edits or deletes. This was not true. I could still
change other fields on the form (with the exception of the
frmTimeDetail) subform. Once I exited the record and came back to the
form, sure enough I could not change the fields. How can I make that
happen sooner -- do I need to issue a save to get it to take effect?
Any other suggestions to do this process? Basically, if someone
approves the time record, I do not want it to ever get changed.
Thanks!