3 Replies Latest reply on Oct 23, 2009 11:54 AM by mrvodka

    Slider field

    skn

      Title

      Slider field

      Post

      I have a field in one of my tables that has a range from 1 to 10, instead of having the user type the actual number is there a way to incorporate a slider for the field, I haven't seen anything in FMP that supports this type of mechanism.

       

      Thanks

        • 1. Re: Slider field
          raybaudi
            

          Hi

           

          If a simple value list isn't a good solution for you, you can:

           

          1) create a number field that auto-enters data: 5
          2) format this field to not allow editing in browse mode
          3) place a text object ( "-" ) to the left of the field
          4) place a text object ( "+" ) to the right of the field
          5) format those objects to act as buttons, giving them the -1 and 1 script parameter and let them fire a script like this:

           

          Set Field [ NumberField ; Min ( Max ( NumberField  +  Get ( ScriptParameter ) ; 1 ) ; 10 ) ]


          • 2. Re: Slider field
            raybaudi
              

            Another way ( if you have FMP 10 ) :

             

            1) create a new calculated field with 10 repeatitions and calc: Get ( CalculationRepetitionNumber )

             

            2) Add to it a OnMouseEnter trigger that fires this script:

             

            Set Field [ YourNumberField ; Get ( ActiveFieldContents ) ]

            Commit Records/Requests [ ]

             

            When you'll enter that repeating field, the number field will take the repeatition value.

            • 3. Re: Slider field
              mrvodka
                

              Perhaps this can help you out or give you some ideas.

               

              http://fmforums.com/forum/showtopic.php?tid/195086#289522