AnsweredAssumed Answered

Difficulty with an "omit find request" script

Question asked by trialuser1111 on Jan 15, 2010
Latest reply on Jan 15, 2010 by trialuser1111

Title

Difficulty with an "omit find request" script

Post

I am having difficulty troubleshooting a behavior quirk in my database, and I think I've narrowed down the culprit to a fairly simple script for omitting find requests.

 

To allow users to perform more complex searches, I have created a dedicated "Find Contact" layout allows users to build multi-step searches in a more visually logical list format.  Next to each row, users have a small array of buttons to add/delete new search steps and designate each step as an "omit" or not.  This is the script assigned to the "Omit" button:

 

Omit Record

If [Get (RequestOmitState) = 1]

   Set Field [Contacts::Include?; "No"]

   Exit Script []

End If

Set Field [Contacts::Include?; "Yes"]

 

The reason for the extra steps is that the field Contacts::Include maps to a conditionally-formatted background (green for include, grey for omit).  Pressing the button does trigger the conditional formatting so I know it's working, and when I show the status bar, I can see the toggle switch back and forth from Include to Omit.  However, when I execute the search, the step is essentially ignored in the results.  I have tried manually switching from Include/Omit in the status bar and creating another button that just toggles Include/Omit without the added steps.  These have both yielded accurate search results.

 

Why would these extra steps impact my search results, and how can I fix it? 

Outcomes