AnsweredAssumed Answered

Modifying field values based on certain criteria.

Question asked by ChrisSmythe on Oct 29, 2012
Latest reply on Nov 8, 2012 by ChrisSmythe

Title

Modifying field values based on certain criteria.

Post

     Hello, I am using FileMaker Pro 12 on Windows XP.

     I am hoping someone would please be kind enough to help me with the following problem:

     I have a link to my Test 15.fmp12 database (Account Name: Admin & Password: "there is no password" just click OK.

     https://www.sugarsync.com/pf/D0681807_60165357_23551

     I have previously posted this before.  It is under the heading of "Calculation for DeployedStatus Field".  Link: http://forums.filemaker.com/posts/2630e3b0a9

     Unfortunately, being a newbie, I was unsure how to ask for what I wanted.  Forum members such as Sorsbuster & S Chamblee were very kind and gave me correct FileMaker code.  I should have asked the right question, but do not have the requisite experience and knowledge to know exactly what to ask.

     I tried using a script trigger on the DateDeployed field and specified the onObjectModify event to run a script that I named: Change DeploymentStatus to Deployed.  Here is the steps in the script (kindly provided by S Chamblee):

     If [DbUserEdits::DateDeployed = Get (CurrentDate) and DbUserEdits::DeploymentStatus = "Pending"]
         Set Field [DbUserEdits::DeploymentStatus; "Deployed"]
     Commit Records/Requests [No dialog]
     End If

     I do not know how to trigger the event?

Background on my database:

     My FileMaker database runs in a 24-hour, 7-days per week Call Centre.  We have two people operating on each shift.  There are 3-shifts per day.  The only time our FileMaker database "goes-down" is when our work computers "go-down".  Our work computer has never "gone-down" for a period greater than 48-hours.

What I need is (possibly a script?) to run at time 0001 (one-minute past midnight) each week day (Monday to Sunday inclusive) in the background (without user intervention).

     I need to change the DeployedStatus field value from "Pending" to "Deployed" when the DateDeployed = CurrentDate for all records in the DbUserEdits table.

Please note that if our work computer "goes down" --- very rare occurrence, then I still need to undertake the above-mentioned change retrospectively.

     Any help would be greatly appreciated.

     Kind regards,

     Chris :)

Outcomes