5 Replies Latest reply on Nov 3, 2016 10:59 AM by JeremyHurd

    Keep Popover Open - Part 2

    JeremyHurd

      Hello FM Community,

       

      Having a very similar issue to what is described here:

      Keeping a Popover open

       

      Following the suggestions and scripting by Erolst in that post, I have created a sample file to try to get the popover to remain open unless the user presses "OK", but it is still closing.  I don't have a good grasp on the Get (ScriptParameters) calculation, so it is very likely that I'm missing a step somewhere.  I probably need to set the parameters to begin with, but I'm not sure on how to do that.  I've exhausted forum and help searches at this point, so any help and further explanation of the ScriptParameters feature would be greatly appreciated.  

        • 1. Re: Keep Popover Open - Part 2
          erolst

          The idea behind script parameters is that you have one set of functionality (script) that returns different results, depending on the input (script parameters). Compare with functions, where e.g. Sum() returns different results for Sum ( 1 ; 2 ; 3 ) and Sum ( 4 ; 5 ; 6 ), respectively.

           

          In this case, the idea is to package a set of related functionalities into one script, rather than writing lots of small scripts … also, by keeping scripts as generic as possible, you facilitate reusing them. Note how the script doesn't refer to any specific object. so you can use it for any popover.

           

          Anyway, check out the attached modified file; see how the script triggers for the Popover panel are defined, including different parameters for different events.

          • 2. Re: Keep Popover Open - Part 2
            rgordon

            I modified your file one more time to allow the new and delete buttons to work.  The popover needs to close to be able to create a new record or to delete a record.  If you want the popover to remain open after the new record or delete, you can add a go to object step to the script to reopen the popover.

            • 3. Re: Keep Popover Open - Part 2
              JeremyHurd

              Aghhhh!  Thank you for the modifications and explanation.  I knew I had to set the "enter" and "exit" parameters, I just had no idea where to do it!  It now works exactly how I wanted it to.  Thanks again!

              • 4. Re: Keep Popover Open - Part 2
                erolst

                rgordon wrote:

                I modified your file one more time to allow the new and delete buttons to work.

                Yes, now that you mention it, I forgot that there is more going on that popover …

                 

                Well, that's what 'peer review' is there for …

                • 5. Re: Keep Popover Open - Part 2
                  JeremyHurd

                  Great!  Yes I didn't notice that the buttons weren't working correctly in the first mod because I clicked the add and delete and saw that there were 2 records and assumed it was working.  Good catch.