start date end date

dmahendran
Tera Contributor

I would like to implement a restriction where the end date cannot be selected beyond one month from the start date

18 REPLIES 18

@Ankur Bawiskar sorry for the delay response.

There’s a change in the requirement. Currently, there’s already an end date in the End Date field. Whenever someone tries to change this end date, the system should restrict them from selecting a new date that is more than 30 days ahead of the existing end date. In other words, users should not be allowed to select an end date that exceeds 30 days from the previously set end date. could you suggest a better way to handle this.

@Nishant8 

@dmahendran 

I believe I have shared solution to your original question.

you can easily enhance it for your new requirement.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

@Ankur Bawiskar tried that it wont work for my case, the issue is from the old value of the end date we need to calculate the newly selected end date that doesn't go beyond 30days if so we need to put an alert, This scenario is not working for me.

@dmahendran 

it doesn't make any sense to calculate the 30days from the earlier selected end date.

user can change the end date multiple times.

it should be validated against the start date only

please discuss this with your customer.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

@Ankur Bawiskar 

This is related to the Contract Extension Catalog. We need to restrict users from extending the contract by more than 30 days from the existing contract end date.