1 Reply Latest reply on Sep 30, 2011 1:35 AM by Sorbsbuster

    Script to go to a Tab (Control Tab)

    dumiya

      Title

      Script to go to a Tab (Control Tab)

      Post

      OSX Lion  Filemaker 11

      On the same layout I have "Field 1" which is a drop down list.

      I have a Tab Control with three tabs in it. Tab 1, Tab 2, Tab 3 each with different fields within them

      I am trying to write a script so that when a certain name is selected in the Drop Down list a script will bring the "Tab number 3" to the front so the user can work in the correct Tab.

      My attempt Script

      If (Field 1 = "name on dropdown list")

           Go To Object("Tab #2")

      End if

      Nothing Happens.  I know it could not be this easy - I am missing something.

      (I must say I get confused with "tabs" and "tab controls")

      I have looked through the Forum but the replies don't seem to work

      dumiya

       

        • 1. Re: Script to go to a Tab (Control Tab)
          Sorbsbuster

          In layout mode click on the tab you want to go to.  Make sure you have clicked on the tab's name so that the actual tab object is selected.  Its title should have a black border.  In Inspector click on the Appearance tab and enter a meaningful name for the tab object.

          Now create a script with one line: 'Get To Object ("[The name that you called the tab]")

          Assign that script to a button on the layout.  You will see that it takes the user to that tab.  Just build that step in to a script wherever you want now.