Hi Sonta,
(aircode)
Private Sub File_Date_AfterUpdate()
If Not IsNull(Me![FileDate]) Then 'Make sure that the user hasn't changed
thier mind
With Me
![Locked] = True 'You'll want to indicate that the record is now
locked.
.AllowEdits = Not Me.Locked
.AllowDeletions = .AllowEdits
End With
End If
End Sub
--
HTH,
Don
=============================
Use
My*****@Telus.Net for e-mail
Disclaimer:
Professional PartsPerson
Amateur Database Programmer {:o)
I'm an Access97 user, so all posted code
samples are also Access97- based
unless otherwise noted.
Do Until SinksIn = True
File/Save, <slam fingers in desk drawer>
Loop
================================
"sonta" <sk**@optusnet.com.au> wrote in message
news:40**********************@news.optusnet.com.au ...
Hi.
Awhile back I got some useful advice in locking records using tick boxes.
Eg a field called 'Locked' was used to tick (yes/no format) any record in the
datasheet view.
But I would like to know how to do the same when a particular date field
(field name: 'File Date') is populated by the user.
Below is the example of the tick box method...wondering if anyone can
modify the method to my question. thanks.
Set the form's Allow Edits and Allow Deletions properties in the
Form_Current() event procedure.
Private Sub Form_Current()
With Me
.AllowEdits = Not Me.Locked
.AllowDeletions = .AllowEdits
End With
End Sub