Forcing a Field to Refresh

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

Guest

Hi,

I have a form with a field that uses the "Default Value" property to invoke
a function to get a default value. When I open the form, this works fine and
the appropriate value is displayed in the field. But under certain
conditions I want to force that field to be "refreshed" (i.e. re-execute the
default value function to retrieve and display a new value). Is there a way
to do this? I have already tried various combinations of Refresh, SetFocus,
Requery, etc., but so far with no success.

Tom
 
The field in question captures a control number from another table that is
incremented by one. The form has a button to start a new record. I have VBA
logic tied to that button to increment the control number. But if the user
clicks
that button with no data entered, Access apparently does not execute the
"save and start a new record" logic. Meanwhile, however, my logic does
update the control number. This is acceptable if only I can get the field on
the form to reflect that new control number. But this is what I can't get to
happen.

Thanks,
Tom
 
Back
Top