2 Replies Latest reply on Sep 11, 2016 2:35 PM by philmodjunk

    Popover-Hosted, Portal-Based Record Selection List

    bee13

      First off, I apologize for my choice of discussion title, which seems overly cryptic, but I had difficulty devising a concise description for my somewhat involved questions below...

       

      ABOUT ME: FMP Advanced 13, Mac OS El Capitan, FM Go 15, novice aspiring to intermediate skill

       

      GOAL: My user (a school teacher) wants a FM Go-based method for a DB I already developed to

      1. present a scrolling list of names for students whose records already exist in a Student table, and
      2. enable the user to tap on various names in the representative list, thereby 'marking' the selected students, from which
      3. a batch is created from which
      4. a separate report is generated for each of the previously selected student records and only those students

       

      BACKGROUND:  I have already placed a popover on a layout that looks at the Student table whose sole purpose is to build & present numerous reports.  Within the popover boundary I have placed a slide control with numerous panes.  Each pane hosts the mentioned report-generating buttons, grouped by similar actions.

       

      Student_Select_Popover.jpeg

       

      It seems technically possible to use one of the popover's/slide control's panes to present the user with the the above-mentioned scrolling list of students from which the user can individually select (mark) student records which are to be included in a report-generation batch.

       

      PRESENT CONFIGURATION:

      1. I created a second table occurrence of the Student Table and related it to the original Student Table via the primary key fields.
      2. I established a cartesian relationship between the two TOs in order to make all related student records visible.
      3. I created a portal with the student Name field and a checkbox and placed it on the 'Reports' popover in the primary Student TO looking into the second Student TO. The checkbox provides a convenient way for the user to 'mark' individual students which are to be included in a batch for report generation.

       

      WHAT WORKS:

      1. The relationship between the two TOs using the cartesian symbol does present all student names and their associated checkboxes in the popover/slider portal.
      2. I can click on random checkboxes and they toggle on and off accordingly.

       

      ASSUMPTIONS

      1. I am unsure whether the construct I have built is the best method or if it will work at all.
      2. I understand that ultimately a script connected to a button (or similar) on the popover must be used to create a found set including only those students whose checkbox fields have been 'marked' via the popover/slider portal.

       

      QUESTIONS:

      1. Am I on the right track?  Is there a better way to accomplish the stated goal above?
      2. Am I completely off base???

       

      Thank you in advance!

        • 1. Re: Popover-Hosted, Portal-Based Record Selection List
          FabriceNordmann

          my two cents: marking records using a field is not something I would recommend:

          - it won't work in a multi-user environment (although you said this one was for a single user)

          - the modification date is updated while in fact the data was not modified

          - you will need to clear the selection at a certain point, and that might not be so easy (you can do it during the "generate report" script, or the "cancel" script, but what if the user wants to create several reports with the same students? And what if the application crashes or simply the user pushes the home button, or receive a call?

           

          Instead, I would recommend to use a global variable or a global field with the list of record IDs. The checkbox (or highlighting) becomes a simple 'consequence' of the content of this global.

          A good function to add/remove one or more items to/from the list is this one: FileMaker Custom Functions | Displaying Function SwitchList

           

          HTH

          • 2. Re: Popover-Hosted, Portal-Based Record Selection List
            philmodjunk

            Actually, I could picture exactly what you wanted assistance with.

             

            Here's a carefully documented FileMaker file that demonstrates many different enhanced value selection methods--including the use of slide controls and popovers with a selection portal plus various approaches to how the list of possible values to select are filtered. You may find it a good source of ideas for inclusion in your own work:

             

            Adventures in FileMaking #2 - Enhanced Value Selection