Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

how to refresh data -bind control?

Let's say I have a data-bind control, then I change the a field of current loaded record by code, then I want to refresh the form to reflect the latest value, how can I do that without closeing and opening the form?

Comments

  • Are the ALL the field you want to 'refresh' symbolics?
    I am assuming that that you are saying that values in other fields are dependent on the value in the changed field.
  • If the fields that are to be refreshed are symbolics, then I assume that you are not seeing them auto updating, so you need to check the following(imho)
    Are you setting the "INVALUE' of the field you are changing by code.
    Is this field referenced in the symbolic using squiggly braces {}, if not, then you may need to change or send a "CALCULATE" event to each of the fields that need to be 'recalculated' when you change the value.
  • @BarryStevens, I mean I have a data bind form which loads a record, then I change the data by
    new_ref<1> = new_value
    new_ref<2> = another_new_value
    ...
    etc then
    write new_ref on table, id..
    so now I want the form to display the latest data value
  • Do you mean the form is clearing after you do the write?
    In form designer




  • @BarryStevens it's not about the write event, I didn't use the write event to update anything, I just use a write statement to modify the current record, and the form is still showing the original values, even I put the cursor in the key field and lost focus, it is still showing the old value, to load the new vlaues, I have to open the form and load the record again
  • @slowjams to be honest, I really don't understand why you are doing this. It seems like you are not really using OI the way it was intended. However, if you know the data has been updated on the server, try sending the form a READ event to re-load the record automatically.
Sign In or Register to comment.