hi
I am trying to lock a field in my table so after a user enters data it will lock. This is my code:
private sub fieldname_change()
if not isnull(me.fieldname) then
me.fieldname.locked = true
else
me.fieldname.locked = false
end iff
end sub
when i try to test it i get a runtime error 2166 "cannot lock a control while it has unsaved changes."
can any one help me figure out why i am getting this error.
thanks
I am trying to lock a field in my table so after a user enters data it will lock. This is my code:
private sub fieldname_change()
if not isnull(me.fieldname) then
me.fieldname.locked = true
else
me.fieldname.locked = false
end iff
end sub
when i try to test it i get a runtime error 2166 "cannot lock a control while it has unsaved changes."
can any one help me figure out why i am getting this error.
thanks