Skip to main content
Question

How to get the business day or weekend

  • February 22, 2024
  • 3 replies
  • 724 views

Forum|alt.badge.img+3

I have to build a logic bot should not run last 2 working days but (means it should not be weekend). How to calculate in A360.

3 replies

Tamil Arasu10
Most Valuable Pathfinder
Forum|alt.badge.img+18
  • Most Valuable Pathfinder
  • February 22, 2024

Hi @Daisy.K2,

Please try with bot schedules.

https://docs.automationanywhere.com/bundle/enterprise-v2019/page/enterprise-cloud/topics/control-room/activity/cloud-schedule-a-bot.html

 

Run repeatedly

Use this option to schedule your bot to run every x minutes or hour on a given day. When you select this option, select the start date, start time, end date, and end time

 

Frequency

Select the frequency for the schedule to run as daily, weekly, or monthly.

  • Daily: Select the number of days you want the schedule to run.
  • Weekly: Select the weeks and the particular days of the week you want the schedule to run. For example, if you want the schedule to run every two weeks on Monday and Thursday, increase the count to 2 in Every option and select the check boxes Monday and Thursday.
 

Forum|alt.badge.img+4
  • Navigator | Tier 3
  • February 27, 2024

@Daisy.K2 Hi Daisy, I have same requirement and i was able to do it with the help of python script. In script you have to exclude last 2 working days and send status to A360 platform. In A360 platform if result from python script is true then bot will run else it will stop. Schedule bot for daily.


Forum|alt.badge.img+12
  • Pathfinder Advocate | Tier 6
  • March 7, 2024

You can use 

Datetime package.

'E': Specify day of the week as 'EEE' (Sun-Sat) or 'EEEE' (Sunday-Saturday).

You can use it and know if its Sunday or Saturday means weekend