Forum Discussion

MikeTamoush's avatar
Qrew Commander
2 months ago

Saved Value is not registering before redirect

I just encountered an issue I have never seen and am wondering if anyone else has come across this.

I have a Formula Rich Text Button that Does the following:

'Class=Save Before Navigating'
Run an API_EditRecord and set a half dozen fields.

I am in Table A, and there is a record in table B being edited.

The problem I am having is I will see the 'Saving' dialogue come up (indicating my record is being saved), but it doesn't always see that  field was changed. Here is an example.

For example, I changed a singular text field (minimally, I removed a period). The auto save ran, but then it indicated '0 fields changed'. Yet, I can see on my launch record the field is in fact saved, without the period. A field definitely changed. (I would post a picture but that seems to be bugged)

This is not consistent. Sometimes I run the test and the edit is made as expected. Another time I will run the test and it doesn't register the change. It is almost as if it is a race against the clock. Sometimes the EditRecord API is running before it can tell a change was saved.

Has anyone else run into this?

3 Replies

  • not sure if table A is the parent table of table B or not. If so,

    edit at least one field in the Table A

    • MikeTamoush's avatar
      Qrew Commander

      Yes i should have mentioned:

      Table A and be are not Related. Table A by definition must be edited, because it is that edited field which is being placed into Table B.

      Ie: Field one table A is changed. This new value is supposed to be copied into Field one of Table B via API_editRecord. The edit record seems to happen before the change of Field one of table A is registered. 

      • MikeTamoush's avatar
        Qrew Commander

        Update: It really does not matter about tables. I tried this in a test environment with a simple:

        EditRecord Api that places Field A, into Field B (Same Table, same record). If you use this api in edit mode (so you change field A, press the button and allow the record to AutoSave), the first couple of times it works exactly as expected. Try a few more times, and it will no longer work. When you modify field A and press the button, it seems to Grab the original Field A value, THEN autosave, then run the editrecord API.

        The strange thing is, the first time, sometimes two times it seems to work correctly (autosave, grab field A value, then edit record). I am baffled why it is inconsistent. I made a video documenting this but the attachment here will not allow attaching videos. I have submitted a customer support ticket and can update here if they respond, but wondering if others have found this behavior.