1 Reply Latest reply on Oct 11, 2014 11:53 AM by philmodjunk

    Get Floating window name?

    JohanLund-Andersson

      Title

      Get Floating window name?

      Post

      Hi!

      I am in the process of making a table-booking database, I use the new function floating window/popover to view the table's information.

      I can't seem to script getting the popover name though, any ideas?

      The function Get(WindowName) returns the document name whereas I want the table-unique id.

      Thanks for all for help!

       

      EDIT:
      The function Get(ActiveLayoutObjectName) doesn't return the name either, seems like neither of the objects button or window becomes active...

       

        • 1. Re: Get Floating window name?
          philmodjunk

          A popover is not a window. It's more like a special purpose tab control. Thus Window functions do not apply.

          An "active" object is the object that currently has the focus, not the popover that is currently open. Which field that currently has a cursor in it would be the active layout object. A button can have the focus, but not because you clicked or tapped it. (That seems strange, but it's an important aspect of FileMaker's interface design that would keep certain other key features from working if it were not true.) A button can get the focus when you exit a field by pressing a key that exits the current field and the button is set to be the next object in the layout's tab order. A popover button will get the focus when the popover panel is closed in a way that does not set the focus somewhere else (such as when the Close Popover script step closes it).

          I want the table-unique id.

          The current table occurrence name can be accessed via Get ( LayoutTableName ) while this get function parameter says "table" it's really the table occurrence specified in Layout Setup|Show Records From for the current layout.

          Only one popover can be open at a time and the OnObjectEnter trigger set on the popover panel (not the button) will be tripped when the popover opens. Thus, a script performed by this trigger can set a global variable to a value that identifies the currently open popover. Any scripts that then need to access this data can simply reference the global variable.