Showing Open Purchase Order / None Found Subscript In A FileMaker Solution

From Dwayne Wright PMP
Certified FileMaker Developer

TWITTER: dwaynewright
YOUTUBE: FileMakerThoughts

Please Note: If you are viewing this page in a news feeder, the images may get munged up a bit or other formatting of the posting may fail. For the best experience, please visit the journal directly by clicking (here).

This report is a very simple ... find these records and go to list view. It is activated from the Reports custom menu, so it can be activated from just about anywhere in the system.

There are a few different things about this script that some fledgling developers might or might not be aware off. I do have an error capture routine, to branch the script if there isn’t any matching records to report upon. If the find does fail, it activates a subscript, so I can reuse the same code in multiple reports. The sorting feature is a little different as well. It didn’t make any sense to sort the returned records alphabetically by status, so it sorts by the matching value list attached to the status field.

Here you can see the report that is activated by a script parameter passed to it by the Reports custom menu. It does show the report in a new window, which is pretty standard for most of the reports I create.

Here you can see my search is actually a couple omits, assuming that everything that is not delivered or canceled is still open.

Here you can see the contents of the “no records found” subscript and there is an error in this code. Can you spot it? Look at the originating script above and that may help. I wrote this post back in 2008 and looked at it today at the end of 2011. I imagine I took the above screen shot before I was finished with the actual scripting. It looks like I'm closing a window when the script above didn't open a new window. This is something that can happen when you try to create a reusuable sub-routine in a script like a no records found situation.

Here you can see the message shown to users when the “no records found” subscript if fired. Notice how vanilla and multiple purpose it is.

Here you can see that the sort routine is using the associated value list settings.
More info about the author and FileMaker in general, contact me at

© 2008 - Dwayne Wright -

The material on this document is offered AS IS. There is NO REPRESENTATION OR WARRANTY, expressed or implied, nor does any other contributor to this document. WARRANTIES OF MERCHANT ABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE EXPRESSLY DISCLAIMED. Consequential and incidental damages are expressly excluded. FileMaker Pro is the registered trademark of FileMaker Inc.