check for change to field value

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I know the "dirty" attribute can be used to see if a form's content changed.
Is there a similar attribute that I can use top evaluate whether a specific
field onthe form was changed?

Thanks,
Dan
 
Compare its Value to its OldValue.

Like this:

With Me.[NameOfYourControlHere]
If (.Value = .OldValue) Or (IsNull(.Value) And IsNull(.OldValue))
Then
MsgBox "No change"
Else
MsgBox "Changed"
End If
End With
 
Thank you Allen ......

Allen Browne said:
Compare its Value to its OldValue.

Like this:

With Me.[NameOfYourControlHere]
If (.Value = .OldValue) Or (IsNull(.Value) And IsNull(.OldValue))
Then
MsgBox "No change"
Else
MsgBox "Changed"
End If
End With

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

dfeigen115 said:
I know the "dirty" attribute can be used to see if a form's content
changed.
Is there a similar attribute that I can use top evaluate whether a
specific
field onthe form was changed?

Thanks,
Dan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top