Auto-Enter Calculations

Calculation fields are fantastic—they save time and ensure error-free results. But they have one serious limitation: You can’t change their values. Of course, you can adjust the calculation itself, or the fields the calculation depends on, but sometimes you need to be able to override a field’s calculated value on a record-by-record basis.

For example, it would be nice if your invoice’s Date Due field automatically showed a date 30 days after the date of the invoice itself. But sometimes you may want to make an invoice due earlier or later, based on special circumstances (like a holiday). If you make the Date Due field a calculation field, you don’t have this flexibility. The solution is to use a normal Date field with an Auto-Enter calculation (see the box on Auto-Enter Calculations).

Like all the Auto-Enter options (Auto-Enter Options), an Auto-Enter calculation automatically fills in a field’s value, but leaves it changeable. You can get all the accuracy and time savings of a calculation field, plus the power to change your mind. Here’s how to put it to use:

  1. Bring up the Manage Database window and switch to the now-familiar Fields tab. From the Table pop-up menu, choose Invoices.

    The fields from the Invoices table appear.

  2. Select the Date Due field in the list, and then click Options.

    The Field Options dialog box makes an appearance.

  3. On the Auto-Enter tab, turn on the Calculated Value checkbox.

    The Specify Calculation window appears. It looks just like it did before, ...

Get FileMaker Pro 9: The Missing Manual now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.