- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-04-2017 03:39 PM
Is it possible to set the discovery schedule to run on a Monday and then again on a Wednesday?
Thanks,
John
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-04-2017 03:46 PM
You can have the script run daily at the time you want it to run.
Then, set the conditional checkbox field to true and in the conditions section define:
- (function() {
- //run on Monday, Wednesday and Fridays
- var day = new Date().getDay();
- return (day == 1 || day == 3);
- })();
This will run the discovery every day, but will only actually execute successfully if it is monday or Wednesday.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-04-2017 03:46 PM
You can have the script run daily at the time you want it to run.
Then, set the conditional checkbox field to true and in the conditions section define:
- (function() {
- //run on Monday, Wednesday and Fridays
- var day = new Date().getDay();
- return (day == 1 || day == 3);
- })();
This will run the discovery every day, but will only actually execute successfully if it is monday or Wednesday.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-04-2017 03:46 PM
Relevant thread here: Custom Discovery Schedule with a Condition Script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-04-2017 04:04 PM
Would this be a client script in the discovery schedule or business rule?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-04-2017 04:15 PM