Are you sure that all fields receiving criteria are indexed? What indexing options do you find specified in Manage | Database | Fields?
Its weird because it goes slow sometimes. It might go slow when "yes" and "no" are selected or maybe just when "no" is selected.
Could indicate that FileMaker is updating the indexing on the specified field. In which case, the first find may be slow and subsequent finds may be faster.
I archived a bunch of records and switched to a different layout while the script is running. One with only the fields necessary for the search. I did run into a different issue however with this solution.
I want to show all the records designated by the script but if the user checks "yes" and "No" in the ::g_search_billed field, I want it to show records that have been billed as well as records that have not been billed. I tried several different ways and none seem to work.
As you can see i created a field called ::billed_search_no because I thought I could search that field and it woud show both yes and no records. Not the case. Any help would be greatly appreciated.
I hope this is clear
With your script, if "no" is selected, both find requests will specify "no" in their search criteria if I am reading your script correctly. You also are stepping through a list of clients from a value list definition. Why do you need to do that? This may or may not be necessary.
If you are going to find records where multiple check boxes are selected from the same field and you want all records that match any one of the selected values, you'd normally create a separate find request for each value selected where all specified creteria except for the check box value is the same, but with yes/no as the only check box values we can use a simpler approach:
#inside the loop...
If [ValueCount ( Tracking::g_Billing = 1 ) ]
Set Field [Tracking::Billed ; Tracking::g_Billing ]
In otherwords, if both values are selected, treat it as though NO values were selected and don't specify any criteria in the billed field as either set of criteria will produce the same found set.
There is another value that could be chosen. the value list of GLOBAL::g_billed consists of YES, NO, LATER. What would I do if i wanted to show all the records that have yes or no but not Later and not empty?
You also are stepping through a list of clients from a value list definition. Why do you need to do that?
There are 5 global fields that that have the same list of clients so the script runs through and creates a find request for each.
There are 5 global fields that have the same list of clients...
Sorry, misread that script step as something very different.
Note: if all fields in your script that start with g_ have global storage specified you do not need to copy that single value into a variable, you can just refer to the global field when specifying criteria. (Using list to put the values from your global client fields makes sense though.)
You'll need a nested loop. The outer loop steps through your list of clients. Your inner loop steps through your list of "yes, no.." values.
Enter Find Mode
set Variable [$K ; value: $K + 1]
Set field [tracking::Startdate ; Tracking::g_date_start & "..." & Tracking::g_date_end ]
Set Field [tracking::Summary ; Get Value ( $_clients ; $K ) ]
Set Field [tracking::Billed ; getvalue ( Tracking::g_billing ; 1 ) ]
Set Variable [$J ; value: 1 ]
Set Field [Tracking::billing ; GetValue ( Tracking::g_Billing ; $J ) ]
Exit Loop If [$J > valuecount ( tracking::g_billing) ]
Set variable [$J ; value: $J + 1 ]
Exit Loop if [ValueCount ( $_Clients ) < $K ]
Set Error capture [on]
Perform Find 
Sweet stuff Phil. Thanks!