Subject Data in Lookupcombo
Author Harvey R Shaw
We have a MyQuery and MyLookUpQuery with TIB_LookUpCombo embedded in
grid. MyQuery data is shown in Grid.

We want to use the data selected in the LookUpCombo for a calculation.
There should be a recalculation each time a new selection is made in the
Lookup.

We loop through MyQuery.BufferFieldByName to get values. This is fine
except for one small detail - the buffer doesn't get updated when the
Lookup changes.

The only way we get fresh data is after a POST is coded, but it is not
desirable for us to POST, just to make the calculation. Among other
things we need to give user opportunity to cancel their work. If we POST
the old data is gone.

We have tried doing our calculation AfterEdit but this does not work -
the new values are not in Buffer. When is the Buffer updated?

Is it possible to loop through Query.FieldByName values and get the
updated values after the user has made a selection in LookUp?

Any suggestions how to solve this are welcome as we have other
situations we need the updated data in such as creating a report. We
have tried looking at all Events and experimenting, but still only way
that works is Post in the CloseUp of Combo - which isn't OK either
because if user uses arrows there is no closeup event.

We believe that AfterEdit or onDataChange should be where our
calculation is placed - but we get the old data here.


Harvey



[Non-text portions of this message have been removed]