8 Replies Latest reply on Aug 22, 2012 2:25 PM by Stephen Huston

    Trouble with Popup Menu field not exiting on Commit

    tcmeyers

      I posted this on the general bug board, but haven't seen a response, so I'll try here. Please excuse the cross-post!

       

      Summary: Commit in OnObjectModify for Popup Menu does not exit field in FMGo 12

       

      Product: FileMaker Go

       

      Version: iPhone and iPad Go 12.0.3

       

      Operating system version: iOS 5.1.1

       

      Description of the issue:

       

      Unlike desktop FileMaker Pro 11 & 12, and iPad Go 11, when a Popup-menu field has a value chosen, when the OnObjectModify script is executed, which consists simply of Commit Record [Skip..; No dialog], the field is NOT exited, and the large touch-style menu is still displayed (or is redisplayed, not sure which).

       

      In iPad Go 11, and in any desktop FileMaker Pro, this is not the behavior. Instead, the record is committed, and the menu does not re-display... which is the expected behavior.

       

      Steps to reproduce the problem:

       

      Try the sample file attached. It has an icon-displaying container calculation (which cannot be entered) sitting on top of a text popup menu that is reduced in size so that the text does not show, unless it's selected. Clicking/touching the icon location actually brings up the menu instead. Choosing a value is supposed to commit the record, and exit the field, displaying the new calculated icon.

       

      Expected result:

       

      Clicking/touching the icon location which activates the underlying popup menu allows a text choice, and when it is made, the menu should disappear, the record commit, and the new icon (by calculation) is shown.

       

      This does work fine in FileMaker Pro 12 (desktop), and did work in iPad FMGo 11.

       

      Actual result:

       

      Clicking/touching the icon location which activates the underlying popup menu allows a text choice, and when it is made, instead of the menu should disappearing, it either continues to display (or is redisplayed immediately), presumably after the commit. This continues to obscure the new icon.

       

      Commit actually does occur, but the field is not de-selected.

       

      This occurs in FMGo 12 for both iPad and iPhone

       

      Exact text of any error message(s) that appear: none

       

      Configuration information:

       

      The simple test file supplied is sync'd to the iOS device, but the actual file that has the problem that prompted this posting is hosted by FMS 12.

       

      This is how I know that the commit actually does occur when a choice is made... other clients immediately see the updated value.

       

      -Troy

        • 1. Re: Trouble with Popup Menu field not exiting on Commit
          Stephen Huston

          Try removing both fields from the Tab Order on the layout.

           

          Popup Menus try to go to the next field in the tab order when modified, and you don't need a tab order with these objects in this layout.

          1 of 1 people found this helpful
          • 2. Re: Trouble with Popup Menu field not exiting on Commit
            tcmeyers

            Stephen,

             

            That helps some... in the real application it solves the problem after a fashion, but only if I remove ALL the tab-ordering on the layout. I do want some though, to make it easier to go from field to field, so it's not a great solution. The simplified example file only had the one field, so in its case, it does solve it.

             

            Doesn't it seem wrong that the field is reselected AFTER a Commit? Especially since it used to work under iPad Go 11?

             

            If you add a couple more fields in the sample layout, if they have a tab order as I'd like (so that I can use the Previous-Next buttons on the iOS selector wheel) then after the OnObjectModify fires the Commit Record, instead of leaving a committed, exited record showing, it goes to the field that does have a tab-order defined.... not the behavior I wanted.

             

            This can stand as a work-around, but I don't see how it can be considered expected behavior. What do you think?

             

            Thanks again,

             

            -Troy

            • 3. Re: Trouble with Popup Menu field not exiting on Commit
              Stephen Huston

              I agree, not expected behavior.

              What happens if you add a second Commit Record step?

              • 4. Re: Trouble with Popup Menu field not exiting on Commit
                tcmeyers

                Stephen,

                 

                Good test.... but adding two Commits in a row in the script produces the same result. Same with 3 commits.

                 

                Interesting, putting a Pause/Resume Script (Duration 5 seconds) after the Commit temporarily shows the expected display, new icon showing and no popup menu active, but after the delay the popup returns. Same if I put a Commit after the delay as well.

                 

                I also tried adding a Commit to the OnObjectExit as well, with no joy.

                 

                Riffing off of the delay test, I separately tried putting an Exit Script [ Result: 0 ] and Exit Script [ Result: 1 ] after the Commit to see if I wasn't acknowledging further processing of the action. Both still behave as described in the original problem.

                 

                OK, here is the weird work-around, if the OnObjectModify script is Commit then Halt Script then everything acts the way I want it, including being able to "tab" between other fields.

                 

                Halt Script really doesn't make any sense, since the script should self-halt, but there it is.

                 

                -Troy

                • 5. Re: Trouble with Popup Menu field not exiting on Commit
                  Stephen Huston

                  I wonder, since you are in a popup menu field, selecting an item should also exit the field based on that field format. Have you tried an trigger on field exit instead of on modify? You would need an exit script True/1 at the end, so I'm not sure a commit will fire within this script either, but it might be worth a try.

                  • 6. Re: Trouble with Popup Menu field not exiting on Commit
                    tcmeyers

                    Earlier I tried having the Commit - Exit Script [ 1 ] on BOTH the OnObjectModify and OnObjectExit, but not just the OnObjectExit only. I just tried that, and still no luck. That one actually doesn't work the desired way under Desktop FMP 12 as well.

                     

                    I wonder if there's something about 12 in general that sort of loses track of script "stack level" in a sense. Several times in the desktop version it has hung up while running a script, usually (checking, by then opening the Script Debugger tool) when a new window is being created, or more frequently a Go to Related Record (probably also creating a window). In the Script Debugger, it appears to be paused on the window-making step, and when I punch the "go" arrow button, the script terminates, but you can't quit FileMaker, can't close windows, can't run another script. There is no "Continue" button, and the Script Debugger is empty. Force-quit is necessary.

                     

                    I don't know if all that has been reported elsewhere, I was sort of dreading it myself.

                     

                    Oh well, I'm just thinking aloud, since the "Halt" step is the only thing that has worked so far. I'm assuming that will render it unusable if you are supposed to activate this control while a script is running... but who knows, maybe it won't actually Halt the outer script if that's where the confusion lies.

                     

                    -Troy

                    • 7. Re: Trouble with Popup Menu field not exiting on Commit
                      jgalt

                      tcmeyers wrote:

                       

                      OK, here is the weird work-around, if the OnObjectModify script is Commit then Halt Script then everything acts the way I want it, including being able to "tab" between other fields.

                       

                      Halt Script really doesn't make any sense, since the script should self-halt, but there it is.

                       

                      Halt script, good one! Thanks.

                      • 8. Re: Trouble with Popup Menu field not exiting on Commit
                        Stephen Huston

                        tcmeyers wrote, in part:

                         

                        Oh well, I'm just thinking aloud, since the "Halt" step is the only thing that has worked so far. I'm assuming that will render it unusable if you are supposed to activate this control while a script is running...who knows, maybe it won't actually Halt the outer script if that's where the confusion lies.

                         

                        -Troy

                        Hi Troy,

                         

                        Just to clarify, the Halt script step is supposed to halt all scripts that are running/stacked at the time it is executed.