FORMULA LANGUAGE


Examples: Performing time-date operations
1. (@Created) This agent example writes "Archive" to the Status field if the current document was created before 1995, and writes "Current" otherwise.
2. (@Modified, @Date, @Today, @Yesterday) This agent example writes "Today," "Yesterday," or "Old" to the ViewStatus field, depending on the date that the current document was last modified.
3. (@Modified, @Date, @Weekday, @Today, @Adjust, @Yesterday) This agent example modifies the preceding example to exclude weekends in assigning "Yesterday." If today is Monday, y is set to today's date minus 3 days; otherwise y is set to yesterday's date. Then y instead of @Yesterday is tested against the @Modified date.
4. (@Now, @Month, @Year, @Day) This example of a computed text field displays today's date in letterhead form. For example, 6/30/95 displays as "June 30, 1995."
5. (@Adjust, @Weekday, @Created) This example of a computed time field displays a date two days from the creation date for the document. The calculation eliminates the weekend by adding 4 days if the creation date is a Friday.
6. (@BusinessDays) This agent displays the number of days in 2001 excluding Saturdays, Sundays, and 10 holidays.
See Also