Please tell us what version of Access you are using, it may change the response you receive.
My initial thought is that you call the macro from VBA on some event and include a line of code to make the change you need.
it would look something like this:
Dim myVar as varType
myVar =...