Date should not be in past
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2024 09:59 PM
Hi All,
As per my requirement Date should not be selected as past if select we should want to clear the date.
If I do with UI Policy with Run Script I'm getting but I should want get with On change client script.
Please let us know how can i get this requirement with out using ui policy for this
Thank you

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2024 10:09 PM
Hi @Sirri , you can use the below script
Harish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-19-2024 05:45 AM
Hi@Harish KM ,
I have tried with this but it not taking current date.
when ever select current date it will showing as error.
but my requirement is we cannot select past date only but we can select current date
Thank you

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-21-2024 05:34 PM
Gi @Sirri share your client script may be your missing <= in condition
Harish

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2024 10:12 PM
Hi there,
Just wondering why you want to do this with Client Script? If you could do this with UI Policy, which is no code, easier to understand for others, less time-consuming, etcetera, why then choose Client Script? Or do you have a requirement behind this that makes using Client Script necessary?
Kind regards,
Mark Roethof
Independent ServiceNow Consultant
10x ServiceNow MVP
---
~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field