Referencing the work done in this topic, I need the same thing except it has to be able to check if that is the current day. The automation in the link will change to the next month if the output is the current date thus losing the output. (I don’t want to store the previous month’s output)
Hi Corey,
Use this to get the current date
DateTime.Now.ToString(“dd-MMMM-yyyy”) then you can use that to compare with the date you want.
Regards,
Chirag
Welcome to the UiPath Community!
Get First day of the moth using Modify Date activity and use If Activity with this condition
dtmDate.DayOfWeek.AsText <> "Sunday" And dtmDate.DayOfWeek.AsText <> "Saturday" And Now.Date = dtmDate
Thanks,
Ashok
Hi Chirag,
So you are saying that the script you wrote won’t get the date of the first of the next month if it is currently the first day of the month?
For example, if today were November 1st would it still output November 1st or would it give the result for the next month, which would be December 2nd?
Thank you,
Corey
It will give you the first working day of next month
How can I get it to tell me if the current day is the first business day of the month? Without just saving the previous month’s result in a storage bucket and referencing it later when the values are no longer equal.
you can recalculate first day of previous month as well and validate instead of storing
cheers
How would I go about doing the recalculation?
Now.addmonths(-1).adddays(-1)
assuming today is day 1 of month if not you get the month and year and add 1
cheers
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.