Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

How to auto change a field after a set time period

(0) ShareShare
ReportReport
Posted on by 255

Hi

I need to add a checkbox field to our Contact records and this field needs to be unticked when 18 months have passed.
So it will initially be ticked when a form submission takes place.
This will happen on a new contact creation but also on a contact update.
On update, the 18 month period needs to start again.

Will a workflow do this?

Many thanks

  • Stuie Profile Picture
    Stuie 255 on at
    RE: How to auto change a field after a set time period

    Hi

    Just waiting on colleague feedback.

    Thanks for asking

  • Marco.P Profile Picture
    Marco.P 2,405 on at
    RE: How to auto change a field after a set time period

    Hi Stuie,

    any news?

  • Marco.P Profile Picture
    Marco.P 2,405 on at
    RE: How to auto change a field after a set time period

    Of course,

    as long as that "student" field is a date time field (you need a datetime field in order to add 18 months and make the comparison)

  • Stuie Profile Picture
    Stuie 255 on at
    RE: How to auto change a field after a set time period

    Hi

    Thanks again.

    OK makes sense.

    I guess my concern now is that if the record is modified at all then the mod date comparison will be effected.

    So if a CRM admin edits anything on that record it will reset the 18 month period right?

    We have another field that sets the date each time a front end user (student) makes a change to the record.

    I guess I can use that date instead so the 18 month period can only be extended by the student and not an Admin.

  • Suggested answer
    Marco.P Profile Picture
    Marco.P 2,405 on at
    RE: How to auto change a field after a set time period

    Hi Stuie,

    don't worry we're here to help.

    You won't add 18 months to  Now(), but to modifiedOn field (the system field that store last modified date).

    I suggest you to create the two option calculated field with a default value of yes (it means that every time a record will be created the "checkbox" will be checked) and then specify the formula by comparing:

    if NOW() is greater than or equal at "modifiedOn+18month" field (it means that the 18moths deadline is expired)

    then set value as No.

  • Stuie Profile Picture
    Stuie 255 on at
    RE: How to auto change a field after a set time period

    OK i like this solution thanks.

    I've set up the fields as described.

    How does this actually work though.

    If we are always adding 18 months to Now() will the condition ever be met?

    Sorry If I'm being dumb :)

  • David Jennaway Profile Picture
    David Jennaway 14,063 on at
    RE: How to auto change a field after a set time period

    You could use either a workflow with a wait condition, or a calculated field (as per the previous post). I'd normally recommend the calculated field, but a limitation is that you can't trigger workflows off it (i.e. if you wanted to notify someone to do something when the 18 months is up)

    An issue with using the workflow is that each update would start a new instance of the workflow. These don't cause a huge overhead on processing, but will take up space.

  • Verified answer
    Marco.P Profile Picture
    Marco.P 2,405 on at
    RE: How to auto change a field after a set time period

    Hi,

    you can achieve that with 3 calculated fields:

    *Example*

    FieldToday (datetime calculated) in action set NOW() as value.

    FieldExpirationDate (datetime calculated) in action set ADDMONTHS(18, modifiedon)

    FieldCheckBox (two options calculated) In condition check this : if FieldToday>=FieldExpirationDate Action: set value to No.

    Hope it helps,

    Marco


    If found useful, please mark the answer as Verified

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Tip: Become a User Group leader!

Join the ranks of valued community UG leaders

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,387 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans