Why Do We Filter From a Mini Window Instead of Right On the Daily View?
We need to script a hard refresh after each time the filters are changed. (A hard refresh involves entering browse mode then entering preview mode.) This is required by the little indicator lights in the mini-calendars used to signal that there are appointments for that day. These indicators respect the filters and unfortunately do not update without a hard refresh.
The reason they donŽt update involves a quirk in FileMaker 7 where calculations more than 2 tables away do not always refresh themselves automatically.
In order to get these calcs to refresh at all, we have to set the filter contents from the Calendar table into the Days and Hours (Pro Version) tables as well. Had we used relationships from Days (or hours) to the Calendar, instead of storing the filters in these tables as well as in the calendar , weŽd have encountered yet another quirk in which the display of hour or mini-calendar appointments would only refresh after a change in field definitions. (The "Filter Calendar - Pass Filters" script is used to move the filters from one table to the others.)
This issues was addressed in FileMaker 7.0v3 with the introduction of the "Flush Cached Join Results" option in the "Refresh Window" command. Utilizing this command would let us dispense with passing globals values to the Days and Hours table as they could becomes calculated values. However, our testing shows that passing these values as we do, and using a traditional hard refresh instead of "Flush Cached Join Results" is noticeably faster on single-user systems and slightly faster on systems using FileMaker Pro Server.
Note that we also have "refresh" scripts running at the end of the scripts used to clear the filters, and to change the show/hide values. These scripts only call the refresh if they are performed outside the filter mini-window. If they are called inside the filter mini-window we're going to hard refresh the screen as soon as the filter window is closed by the continue button: no sense refreshing twice. (The "Commit and Refresh" script is used to perform these hard refreshes.)