3 Replies Latest reply on Mar 12, 2012 10:18 AM by philmodjunk

    List view records jumping around on record commit.

    user17265

      Title

      List view records jumping around on record commit.

      Post

      PhilModJunk suggested I post this issue.  I have a layout in list mode used for parts ready for the next step in a process.  Several lots may be combined into one for the next process step so I have a button that puts a value in the clipboard, that can then be pasted into new records with a click in its relevant field.

      But at the initial step, when comitting the first record update, the record jumps to a different place in the list.  There are no sorts involved in the script that copies or pastes these numbers.  The only script steps are Set Field and Set Variable.

      On exploring more it appeared that FM was re-activating an earlier sort.  I sort on 3 fields coming into the layout, and have buttons on the columns to sort by those fields, and was not using the third field in those column sorts.  But FM was still sorting on that third field whenever I commited an edit change.  I deleted that third sort field in the script that loads the layout and the problem went away.

      Are sorts supposed to remain active w/o being called on?

       

       

        • 1. Re: List view records jumping around on record commit.
          philmodjunk

          FileMaker maintains the current sort order when you edit a field referenced in that current sort order. As a test, select Sort from the records menu and check to see what fields are specified in that sort order just before you start editing records. FileMaker will maintain that sort order, moving the record you edited to a different location in the found set if a value in one of the fields specified in the sort order was modified. This appears to be what you have taking place here. Many have complained about this "auto-sort" and have requested that FileMaker Inc. at least give developers the option to disable the auto-sort for specific layouts. Keep in mind that a sort order can specify multiple fields and that editing any one of the fields specified in the sort order can result in the record "jumping" to a new spot in the sort order in order to maintain the sorted order of records.

          As described in the thread where you first posted, this auto-sort can be temporarily disabled by editing your data while a script is paused. When a script is paused, the auto-sort won't kick in until you continue or halt the paused script.

          • 2. Re: List view records jumping around on record commit.
            user17265

             Thanks, the documentation could be a little clearer that sorts remain active indefinitely.  I tried turning off sorts by following a sort by another that sorted on nothing, but that didn't seem to have any affect.  It is odd that there is no way to turn this off. 

            • 3. Re: List view records jumping around on record commit.
              philmodjunk

              You have the option to Unsort the records. That would also disable the sort, but it also re-orders your records into the order they were originally created or imported into the table.