4 Replies Latest reply on Jul 8, 2013 6:48 AM by NormD

    Find a particular colour in a field



      Find a particular colour in a field


           This has to be so simple that I'm just overlooking it. My database has a field called Product Number that lists various products by a unique number. I set up a script button (photo) that changes the colour of the number to red if that product needs to be photographed. Now all I want to do is isolate one color and keep them (red) or delete them (black). Sounds simple but I can't find the right method.

           Any ideas would be appreciated. Thanks.


        • 1. Re: Find a particular colour in a field

               What is the "value" that you use on the button script to change the formatting to red [or black]? That is the criterion to use to isolate the record(s).

          • 2. Re: Find a particular colour in a field

                 Hi Fran,

                 Thanks for helping me get my head around this. When you say use the "value" of the button script as the criterion, I'm not sure where/how to apply that. The button calculation, actually changes the color from black to red so I assume I only use a portion of the script?

                 My original thought was a simple approach with the Find command like, "Find all red text in the Product No. field". I tried a few scenarios with search criteria but the syntax may have been a little wonky.

                 Could this possibly be an "If" or "Case" function?



            • 3. Re: Find a particular colour in a field

                   It appears that you are clicking a button to "mark" a specific record by changing the text color of the field.

                   Instead of actually changing the format of the data like this, consider using a conditional format setting to display the text as read. You can set up a number field: NeedsPhoto and you can format it as a single value check box field with 1 as the only possible value. Click the check box to flag the product record as needing a photo and click it again to clear it. THe field can be resized to hide the 1 so that only the check box is visible.

                   Your conditional format expression would then be:


                   and you can perform a find for a 1 in the NeedsPhoto field to find all records for products that need a photo.


              • 4. Re: Find a particular colour in a field

                     PhilModJunk, that actually worked really well. Thanks for the insight!