How do I create a formula that updates a field when a record is created?

  • 0
  • 1
  • Question
  • Updated 3 years ago
  • Answered

 I want the Time Call Received field to update with the current time when a new record is created in a Phone Call Tracking Table.  The Time Call Received field is currently a Formula - Date/Time field.

Photo of Doreen

Doreen

  • 0 Points

Posted 3 years ago

  • 0
  • 1
Photo of Xavier Fan

Xavier Fan, Champion

  • 340 Points 250 badge 2x thumb
Can you post your formula for [Time Call Received]?
Photo of Doreen

Doreen

  • 0 Points
[Date Created] is the formula.  this inserts the time the form is closed.  I want the field to reflect the time the form is opened.
Photo of Xavier Fan

Xavier Fan, Champion

  • 340 Points 250 badge 2x thumb
You can use a dynamic form rule to fill in a Date/Time field with the current Date/Time - when the record is opened.

Say you have a Date/Time field called [Time Call Received - Date/Time]

Now create a form rule:   (your plan needs to be Premier and above - the Essential plan doesn't have access to dynamic form rules)

When [Time Call Received - Date/Time] is equal to (blank)

change [Time Call Received - Date/Time] to the current date/time

and uncheck Fire "change" actions only when a condition changes from false to true



With this form rule - when you create a new record - the [Time Call Received - Date/Time] field is filled in with the date/time when the form was opened.  Then when it's saved, that date/time gets saved as well.

As a form rule - this doesn't work if records are added via Grid Edit.