simple goto the form in which u want this
and dbl-click on Properties button leftmost to Scale/Measuring line
then goto Event Tab
There are many events in form, like Onload, OnUnload, OnKeyUP
AfterInsert
if you wish that before adding/after adding a record your query/SUB VBA shud
check then...