How to get the previous month First and last date

Hi all,

I need to get the first and last date of the previous month

First date - 01.01.2022
Last date - 31.01.2022

1 Like

Hi @Clinton_Das

Use Assign Activity

LHS → create an variable

RHS →

First Date → New DateTime(Now.Year,Now.AddMonths(-1).Month,1).ToString(“dd.MM.yyyy”)
Last Date → New DateTime(Now.Year,Now.Month,1).AddDays(-1).ToString("dd.MM.yyyy")

Have a look on the thread

Regards
Gokul

2 Likes

You can refer to the post below.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.