7 Replies Latest reply on May 4, 2016 11:10 AM by alc

    Simple Go To Layout (by calculation) fails


      I have 2 very simple scripts designed just to go back to previous layout.


      script 1 (set up as an on exit layout script Trigger)

      Set Variable ($$lastLayout)


      script 2: ( attached to a button )

      Go to Layout [ $$lastLayout ]

      //  above by using Layout Name by Calculation option

      //  since testing hard coding a layout name worked, I even tried GTL ( GetAsText ($$lastLayout)


      data view shows that the variable is set correctly, but when I click the button, nothing happens. Script Debugger indicates no error..


      When all that failed I Tried: passing LayoutName & LayoutTableName following FP script reference notes**:


      Like this: Go To Layout [  $$lastLayout &  "(" & $$lastTable &")" ]


      **"  When a file has two or more tables, FileMaker Pro appends the name of the source table to the layout name for clarity. For example, Go to Layout [“Layout #2” (TableB)]. "


      I Give. This should be such a no brainer. whats the trick to Layout Name by Calculation?