1 2 Previous Next 15 Replies Latest reply on Oct 20, 2016 10:05 AM by Oodua

    Conditional Values List


      Attached is a simplistic example of what I am attempting to accomplish.  In this example I have a radio button, and what I would like to do is depending on which is selected "Pants" or "Shirts", only the colors associated with the selected option will appear in the pop-up menus "Color" and "Second Color".  Unlike the "Shoes" portal section where you have multiple choices, I would like the"ATTIRE" section to be conditional, depending on the type that is selected (pants or shirts).  I attempted to display values from two separate fields, but that didn't quite work the way I wanted it too.  Any help is much appreciated.

        • 1. Re: Conditional Values List
          David Moyer


          this might be what you are looking for - an example I made in FM 14 ...

          1 of 1 people found this helpful
          • 2. Re: Conditional Values List

            Instead of separate tables, use one table for both pants and shirts. make one field in that table Attire to specify the type of clothing and another field the color.


            You then set up this relationship


            ClothesExample::PantsShirts = AttireColors::Attire


            Data in your table will look like this:

            Attire         Color

            Pants         black

            Pants         blue

            Shirts         red

            Shirts         white


            You can then set up a "use values from field" value list to list values from Color from the AttireColors table occurrence. Final step is to select "include only related values, starting from "ClothesExample".


            This is just the simplest and most typical conditional value list. Many other types of conditional value lists as well as other value selection controls are possible in today's filemaker.


            To see some other working examples of conditional value lists and enhanced value selection techniques, see:


            Adventures in FileMaking #1 - Conditional Value Lists

            Adventures in FileMaking #2 - Enhanced Value Selection

            1 of 1 people found this helpful
            • 3. Re: Conditional Values List
              David Moyer

              That's hilarious.  I chose Pants and Shirts for my sample file a couple of months ago.  I must be psychic.

              • 4. Re: Conditional Values List
                David Moyer

                Hi again,

                I modified my sample file to make it more "professional" in that it uses serial numbers to connect to the chosen product records, instead of a multi-predicate relationship.  The choosing process is still a multi-predicate global relationship.  I believe they call this "magic key".

                • 5. Re: Conditional Values List

                  Hi David, that doesn't sound like a typical use of MagicKey, though I haven't looked at the actual file. Every time I've used magic key, it's been a single pair of match fields,


                  MagicKey is a method used to create new related records without changing layouts and without opening a new window. Not something that has anything to do with a conditional value list.

                  • 6. Re: Conditional Values List
                    David Moyer

                    yeah - I'm not good with the lingo.  I spent 20 years developing FM in a vacuum.  There are common things I've been using for a long time that I "invented" on my own.  Anyhoo - I guess "conditional value list" also has a definition I'm not familiar with.  My file just demonstrates an easy way to drill down through product-style-color easily; size would be a fourth parameter.

                    • 7. Re: Conditional Values List

                      Then we are providing "complimentary assistance" and that's all to the good.


                      But using a term differently from how the rest of the community uses it can lead to confusion.


                      A conditional value list is a very commonly used term for a value list where you use the value in Field A to control what values are listed in a value list set up on Field B. A relationship is commonly used for this, but as my adventures files demonstrate, there are actually quite a few variations possible for a CVL and a number of "value selection" tricks that extend beyond the limits of what a simple value list can do in FileMaker.


                      I used to complain that Value Lists in FileMaker are primitive when compared to other products. For decades, the type of "combo box" that you can set up in Access runs rings around a FileMaker value list, but with the advent of popovers and slide controls, the gap has narrowed considerably since I can now set up value selection widgets in FileMaker that reproduce much of the capabilities that a FileMaker Value list lacks.

                      • 8. Re: Conditional Values List
                        David Moyer

                        Hi Phil ... now I'm confused.  I have three hierarchical value lists - the second based on the first selected value and the third based on the second selected value.  What am I missing?  Thanks in advance.

                        (sorry JeremyHurd  for cluttering your post.)

                        • 9. Re: Conditional Values List

                          A lot of good information here.  Thank you for all the advice.  The example you sent David is great, thank you.  I'm also in the process of reading over the documentation that Phil sent to understand these lists better.  I'll play around with the example I set and get back to you guys later this afternoon.  But I think I have plenty of info now to make this work.   Sorry if I use the incorrect lexicon, still new to all of this and I'm learning as I go.  Some of these issues that I encounter are hard to articulate...

                          • 10. Re: Conditional Values List

                            The confusion was mine. I did say that I hadn't looked at your file...


                            My original post was to question you on the use of "MagicKey" as this doesn't normally use more than one pair of fields and is a technique for adding/editing data in related records. A very useful trick but not a conditional value list. You then posted "I guess "conditional value list" also has a definition I'm not familiar with." and then I responded to that comment.


                            Had I looked at your file, I would not be posting this response now.

                            • 11. Re: Conditional Values List

                              Do you want to see only the related Colors to either Pant or Shirts when you create new records or during Find Mode?


                              I was able to recreate your database such that when I clicked "New record", only the colors associated with either Pant or Shirts were displayed as Value list in Color field depending on which attire (Pant or Shirts) that I selected in the Radio button.


                              I also did the same thing for the Find Command such that when I entered Find mode, if I selected Pant, only colors associated with Pant were be displayed as Value list in the Color Field.


                              I do have a question regarding the Second Color Field, what do you want to display here? May be I am missing something in your naration. Please explain. Once I understand, I may or may not add this field before I upload my answer.

                              • 12. Re: Conditional Values List
                                David Moyer


                                I'm normally a stickler for nomenclature - everybody in a business/industry should know and use the same terms, in order to communicate efficiently.  FM is an area that I'm so self-taught, I don't know the jargon very well.  A former boss offered to send me to a FM convention - I turned it down, to my regret.

                                • 13. Re: Conditional Values List

                                  Hello Oodua,


                                  I'm more interested in Browse mode, and what you have described in your second paragraph is what I was trying to accomplish.  When the user selects either pants or shirts they only see the color options associated with that type of clothing.


                                  In regards to my narrative, I didn't quite explain the Second Color field, but that is just a duplicate of the First Color field that I wish to behave identically to the First Color field.  Basically the user can add two pant or shirt color choices depending on which is selected by the radio button.

                                  Thanks for looking at the file!


                                  • 14. Re: Conditional Values List

                                    Hello Mr. Moyer,


                                    It is called “Conditional Value List” because based upon your selections in one field (for lack of proper name), only the associated values related to your selection will be displayed for you to pick from in the other or dependent field.


                                    For instance, I have a field named State and another field named City.

                                    During record creation (Browse mode) or Find mode, I only need to see the names of the Cities based on the State I select.

                                    This is called “Conditional Value List”


                                    I use this approach a lot is some of my Databases so that users are limited to only what they need.




                                    BMW Manufacturing Co., LLC

                                    Toye Odumakinde

                                    Method Engineer - Electrical

                                    1400 Highway 101 South

                                    Greer, South Carolina 29651

                                    Tel:       +1 864-802-5660

                                    Mobile: +1 864-337-4587

                                    Fax:      +1 864-801-5660



                                    1 of 1 people found this helpful
                                    1 2 Previous Next