Alert on new FileMaker Record creation
Alert on new FileMaker Record creation
- Subject: Alert on new FileMaker Record creation
- From: Kai Edwards <email@hidden>
- Date: Tue, 04 Dec 2001 04:11:27 +0100
>
Date: Fri, 30 Nov 2001 11:19:02 -0600
>
From: ehsan saffari <email@hidden>
>
Subject: Re: Alert on new FileMaker Record creation
>
To: AS Users <email@hidden>
>
>
On 30/11/2001 10:31, Robbie Newton <email@hidden> wrote:
>
>
> (Snip) ...I cant figure out how to make FileMaker alert me if there is a new
>
> record (bug) entered into the bug report database. I was just thinking this
>
> morning that maybe I could use AppleScript to write something like that. Does
>
> anyone have any idea if this is possible before I spend hours trying to
>
> figure it out?
>
>
Not an AppleScript from within FMP (I wish!), but you can have a stay
>
open applet with an idle handler that periodically checks the named
>
(open) db's record count and should it have changed since last check,
>
then throw an alert.
There is an alternative method of triggering actions that I've used in
certain situations. However, this relies on the use of on-screen buttons (or
script menu commands), rather than the standard FMP menu
commands/keystrokes.
I originally adopted the following approach when I discovered several
databases containing a number of empty or half-completed records. (Users
were apparently creating new records and then forgetting to complete them
before selecting other records or closing the database.)
Firstly, to ensure that new records are created in a controlled way, access
privileges are set so that standard menu commands are not generally
available.
Next, a set of global fields are created, corresponding with the local
record fields that require user entry.
Finally, a 'New Record' layout is created (accessed via a 'New Record'
button on the standard layout). This additional layout presents the global
entry fields to the user as a sort of dialog - along with a couple of
buttons labelled something like 'Save' and 'Cancel'.
If the 'Save' button is clicked, it triggers a script to create a new
record, check the new entries (as required), copy the global data to the
local fields in the new record - and return to the standard layout/view.
At the same time, such a script could call another FMP or AS script to take
whatever additional action may be required - such as displaying an alert or
automatically sending an email message summarising the new record.
--
**********************************
Kai Edwards Creative Resources
1 Compton Avenue Brighton UK
Telephone +44 (0)1273 326810
**********************************