2 Replies Latest reply on Mar 2, 2016 6:32 AM by dtcgnet

    Highlight a number not in my value list

    evgomes

      I have a bunch of cost centers entered in a value list. Is it possible to highlight a cost center to a specific color if it is not in the value list?

      In other words, if I enter a number not in my value list can I have filemaker automatically highlight the field YELLOW?

        • 1. Re: Highlight a number not in my value list
          CamelCase_data

          Sure, e.g. using conditional formatting with a formula along the lines of:

           

          not IsEmpty ( CostCentre::CostCentre ) and FilterValues ( ValueListItems ( "" ; "CostCentres" ) ; CostCentre::CostCentre ) = ""

           

          I guess it may not work in your case, but in general, one may want to add a field validation criteria to only allow values that are part of the value list.

          • 2. Re: Highlight a number not in my value list
            dtcgnet

            Set a global variable to the values in the value list. When you set that depends on your need. Do it like:

             

            Set Variable $$ValueList = ValueListItems(fileName;valuelist)

             

            Then on the field with CostCenter, enter a conditional formatting option such as:

             

            PatternCount ( $$ValueList ; Table::TheFieldYouWantFormatted ) = 0

             

            Anytime a CostCenter isn't in the value list, it'll take on the formatting you apply.