Refresh in adp

  • Thread starter Thread starter Tim Ramas
  • Start date Start date
T

Tim Ramas

I have a form in an .adp that is set to view Single Form by default, so that
I can
view/edit data for an individual record. The form is based on a SQL view
with multiple joins and the form has a designated Unique Table. There are a
number of combo box controls on the form that allow for the change/input of
data for the individual record. The properties of the combo box are set
such that a SaveRecord is executed After Update.

The issue is that when a value is changed using the combo box, the
corresponding data that is displayed on the form is not updated unless a
requery is performed. A requery is undesirable because 1. it takes longer
than desired and 2. the form is not returned to the record that was
displayed at the time the requery is performed.

Is there a way to refresh the data in the current record of a form (I will
requery if necessary) and have the form return to that particular record
after the refresh or requery?

TAR
 
My suggestion would be to use a stored procedure with a parameter looking at
the view as your form source. All you need to do then is change the input
parameter for the form after the update of the combo box and your form will
go to the correct record.

HTH,
Jim
 
re:
The properties of the combo box are set
such that a SaveRecord is executed After Update.

What exactly does this mean, codewise?
If you are trying to update the row in the database whenever the user
changes the combobox, then you should effect this by including
'me.dirty=false' in the after update eventproc.
And, just to make sure, the combo boxes in question are data bound, right?
Is there a way to refresh the data in the current record of a form (I will
requery if necessary) and have the form return to that particular record
after the refresh or requery?

Yes, as other posters will attest, but, it should not be necessary if I
understand your aims.
 
Back
Top