I have created a data entry form as shown below.
So in this form all the fields get locked one data is eneterd and after that no one can delete it.
But i have one problem here which is when i m trying to create a new data entry since the files SOPID is number, 0 is the default value that shows up into form for the new entry. So that lock that field on the form and isnt allowing to enter new data into field.
What should i do, if there a 0 dataenter can be allowed if other than zero then it should be lock.
I have use before update event code, and code is mention below. Please help me what are the changes are i require to do from the code below to allow dataentry even if its 0 in SOPID field.
[code]
Private Sub Form_Current()
Empid.Locked = Not IsNull(Empid)
sid.Locked = Not IsNull(sid)
sdot.Locked = Not IsNull(sdot)
Note.Locked = Not IsNull(Note)
eid.Locked = Not IsNull(eid)
edot.Locked = Not IsNull(edot)
cle.Locked = Not IsNull(cle)
End Sub
[/code]