| Computers Forum Index » Computer - Databases - MS Access » How to lock one field in VBA... |
|
Page 1 of 1 |
|
| Author |
Message |
| Simon... |
Posted: Mon Oct 26, 2009 5:15 am |
|
|
|
Guest
|
Dear reader,
In a datasheet form you have the possibility to set the field property
Enabled to No.
With this property you lock the field to prevent editing by the user.
How can I change this field property with VBA.
In VBA I have found Me.AllowEdit = False but then the whole record is locked
for editing.
Is it also possibility whit VBA to lock only the field which has the focus
for instance?
I use now the following code but than the whole record is locked.
If Me.Doc_PTYesNoID = 1 Then 'Progress Template = Yes =1 update by
pick list not allowed.
Me.AllowEdits = False
Else
Me.AllowEdits = True
End If
Thanks for any help
Simon |
|
|
| Back to top |
|
|
|
|