13 Replies Latest reply on Dec 4, 2008 11:37 AM by TSGal

    Impossible in list view?

    Diegus

      Title

      Impossible in list view?

      Post

      Well, I don´t know if what I want its possible in List view. The thing is, I want to be able to move a record above or on top of another record with a button. It´s is possible?

      Any help? 

        • 1. Re: Impossible in list view?
          davidanders
            

          In List View

          You can view ALL records or a subset

          The records can be unsorted or sorted by one or more fields

           

          If you view all records

          AND sort by a field for List View Order

          you could switch the contents of the field with the contents of a record below or above

           

          So, yes, sorta.

          There may be a more sophisticated solution, this would be easy. Given the restrictions.

           

          • 2. Re: Impossible in list view?
            Diegus
              

            That sounds promising, can you explain it a little bit further? please?

            Thanks in advance. 

            • 3. Re: Impossible in list view?
              TSGal

              Diegus:

               

              Thank you for your post.

               

              In your Header, create a graphic and format it to be a button.  Have the button sort the file by the field you want.  Then, when you add the record, click this button, and it will display in the appropriate position.

               

              TSGal

              FileMaker, Inc. 

              • 4. Re: Impossible in list view?
                Diegus
                  

                Hi, thanks for the answer, I was trying with a button and a script, the script goes like this:

                 

                go to layout [ your list view ( table ) ]
                if [Table::SortOrder = 1 //first in the list ]
                halt script
                end if
                go to record [ previous ]
                set field [ Table::SortOrder ; Table::SortOrder + 1 ]
                go to record [ next ]
                set field [ Table::SortOrder ; Table::SortOrder - 1 ]

                sort records [ restore, SortOrder ascending , no dialog ] 

                 

                But when I delete a record the script no longer work...

                 

                Any ideas?

                 

                Thanks!!! 




                • 5. Re: Impossible in list view?
                  TSGal

                  Diegus:

                   

                  If you delete a record, there is no reason why the script wouldn't work.  The worst that could happen is that you have a gap in the numbering sequence, but the data would still be there.  What is occurring?  From your example script, how is SortOrder entered?  If nothing is entered, then you could have a negative result (-1) and the record would be listed first.

                   

                  TSGal

                  FileMaker, Inc. 

                  • 6. Re: Impossible in list view?
                    Diegus
                      

                    The SortOrder it´s an autoserial number field..

                      

                    • 7. Re: Impossible in list view?
                      TSGal

                      Diegus:

                       

                      Thank you for the additional information.  However, you still haven't told me what is occurring.  The only possible problem I see is having two records having the same SortOrder value, but other than that, it should work fine.

                       

                      TSGal

                      FileMaker, Inc. 

                      • 8. Re: Impossible in list view?
                        Diegus
                          

                        Thank´s!!! While I was coping the scritp to explain a little bit further the problem I have... Well I discovered a missing part on the script... so big thanks for helping me out.

                         

                        So I have another consult to make, while the last was my first concern, I have another issue, my database consist in two files related a FileA and a FileB, but I need to, very often, create a clon file from FileB and place it in other directory, let´s say the desktop, but when I do that, the FileB cloned can´t find the FileA anymore, even if the FileA it´s already open...I´ve tried  everything with the File References dialog.

                         One more time thanks in advance.. 

                        • 9. Re: Impossible in list view?
                          TSGal

                          Diegus:

                           

                          Thank you for your post.

                           

                          The Clone of File B has lost the reference to the File A.  Therefore, remove the reference and recreate the reference.

                           

                          TSGal

                          FileMaker, Inc. 

                          • 10. Re: Impossible in list view?
                            Diegus
                              

                            Thanks.... for the quick response!:) 

                            How I avoid the loss of the reference?  I´ve have to do it with every file?

                             

                            And one last thing...  Is there a way to reset to 0 an auto-entered serial number? Without the Layout Mode?

                            • 11. Re: Impossible in list view?
                              TSGal

                              Diegus:

                               

                              The reference runs both ways.  FileA is related to FileB, and FileB is related to FileA.  If you make a clone, the relationship still exists, and the relationship expects the tables to be in the expected directories.  If you move one of the files, the relationship may need to be reset.  Making a clone of the file still leaves the original file in the same location.

                               

                              To reset an auto-enter serial number field, simply go into "Manage -> Database", select the Fields tab, double-click the field in question, and change the starting number back to 1 (or zero).

                               

                              TSGal

                              FileMaker, Inc. 

                              • 12. Re: Impossible in list view?
                                Diegus
                                  

                                TSGal:

                                 

                                Great explanation for the reference, I will find another way to do it.

                                 

                                And, can I reset the auto-enter serial using an script? 

                                • 13. Re: Impossible in list view?
                                  TSGal

                                  Diegus:

                                   

                                  Yes, you can reset the auto-enter serial using a script.  Use the command:

                                   

                                  Replace Field Contents [No dialog; <auto-enter serial field>; Serial numbers ]

                                   

                                  Set the serial number option to "Custom Values" and put in the initial value.

                                   

                                  TSGal

                                  FileMaker, Inc.