6 Replies Latest reply on Jan 12, 2012 12:36 PM by comment

    Filemaker 5


      How do you use the Valuelistnames option in the calculation field?

        • 1. Re: Filemaker 5

          I believe the calculation function you need is :


          ValueListItems (dbname, valuelist) - where dbname is where the Value List is defined, and valuelist is the name of the Value List.


          You would make your results dependent on a CASE statement :


          Case(Field1 = "A", ValueListItems (dbname, valuelistA), Field1 = "B", ValueListItems (dbname, valuelistB))


          where valuelistA and B are two new ones set up to contain just the values you require in each case.


          I've not tested that out - you might want to have a play around with it.

          • 2. Re: Filemaker 5

            ValueListNames ( filename ) will return a return-delimited list of all the names of the value lists in the database. You can use this in a calculation field in a number of ways. In current versions of FileMaker, perhaps the easiest is using a Let statement. For example,


            Let ( $valuLists = ValueListNames ( Get ( FileName )) ;


            $valueListNumber5 = GetValue ( $valuLists ; 5 ) ;


            [rest of calculation goes here] )


            In this cheesy example, $valueListNumber5 would contain the fifth numbered value list in the database.


            I notice you titled this thread "FileMaker 5", so you won't be able to use Let or variables, though, so it might be good to use the function either in a Set Field step in a script, or in a calculated field. It might help if you gave us a bit more detail about what you're trying to accomplish.



            • 3. Re: Filemaker 5

              Exactly what I am trying to do…. I’ll play around and see if I can get it to work.


              Not sure I understand where dbname is where the Value List is defined

              • 4. Re: Filemaker 5

                Here is my actual function that I am trying to get right. How can I get this to choose between value lists?




                Case(Length Of Pull Out = "4.5",ValueListItems("Orientation Of Pull Out", "A" ),Length Of Pull Out = "2.5",ValueListItems( "Orientation Of Pull Out" , "B" ))

                • 5. Re: Filemaker 5

                  I have a value list A and B.....  it is determined which to use by the size of the part.

                  Length Of Pull Out has a drop down consisting of 4.5 and 2.5

                  the next drop down "Orientation Of Pull Out" shoukld be determined by the answer to Length Of Pull Out

                  if Length Of Pull Out is 4.5 i need value list A

                  if Length Of Pull Out is 2.5 i need value list B

                  • 6. Re: Filemaker 5

                    This is a duplicate thread: