Locking fields with existing data

  • Thread starter Thread starter Heather
  • Start date Start date
H

Heather

I'd like to know how to lock a field in a form that has
existing data, however would still allow me to add
information to that field when I insert a new record. I
only want to lock two fields in existing records, not
entire record entries. Any suggestions?
 
try sonething like this

on current event of your form


if me.newrecord then
me.field1.enabled = true
else
me.field2.enable =false
end if
 
I'd like to know how to lock a field in a form that has
existing data, however would still allow me to add
information to that field when I insert a new record. I
only want to lock two fields in existing records, not
entire record entries. Any suggestions?

One would be to use the Form's Current event:

Private Sub Form_Current()
Me!txtThisTextbox.Enabled = Me.NewRecord
Me!txtThatTextbox.Enabled = Me.NewRecord
End Sub
 
-----Original Message-----
I'd like to know how to lock a field in a form that has
existing data, however would still allow me to add
information to that field when I insert a new record. I
only want to lock two fields in existing records, not
entire record entries. Any suggestions?
.
Is there any way to do this WITHOUT code, or can someone
explain the way I should use the code provided? I'm very
sorry, I know just enough about Access to damage a good
database! :)
 
Back
Top