How to Select MTD Date Range on Daily Basis

Date Range

Please help me on this, how to Select MTD Date Range on Daily Basis.

Hi @Vijay_R1

Could you elaborate the question clearly then we will get better understanding of it.

Hi mkankatala,

I want to download the data from website on “Month to Date”.

This data I will download on daily basis and I have done all the process.

Now I’m stuck in date range part, that I want to know how to select the range from 1st Jul-2023 to 19th Jul-2023.

The same step I want to run on daily basis.


  1. Create two variables to hold the start date and end date:
  • currentDate = Now
  • startDate = New DateTime(currentDate.Year, currentDate.Month, 1).ToString(“dd/MM/yyyy”)
  • endDate = currentDate.ToString(“dd/MM/yyyy”)
  1. Use the “Type Into” activity to input the date range:
  • For the start date field - Use the “Type Into” activity to input the value of the startDate variable into the start date field on the website.
  • For the end date field - Use the “Type Into” activity to input the value of the endDate variable into the end date field on the website.

Hope it helps.

You don’t need to create the variables. You can just put the expressions directly into the Type Into activities.

Can’t you just Type Into or Set Text into the text boxes for the dates?

If it won’t let you do that, you’ll have to create dynamic selectors to click the dates you want.

Hi Paul,

Am very new this UiPath, yes I want use dynamic selectors to click the dates.

From the website I cannot type the date manually, it’s only option to select the “Date Range”.

In this situation I don’t know what to do. Can you please help me on this.

Thanks Supriya,

This i’ll do the steps as well.


Pass the two variables in the type into activities strict selectors.


Please check this and try implementing similar to it…it is the same requirement with different website


Hi Anil, thanks.

Am unable to open the attachment and getting error.


Please follow the screenshots…I have uploaded those as well

I have created it in studio and not in studiox


Try the Set Text activity. It often lets you set the value of fields you cannot Type Into.

Otherwise, open UI Explorer, click a date, and show us the selector it gives you.

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