Does file(today downloaded) exist?

I am in a Automation where automation proceed only if “xyz.xlsx” file exist in a folder and that file should be downloaded today. otherwise terminate the automation.(file name don’t contain the download date) how can do this?

Hi Hemant_Deshmukh,
Please check this workflow.
Main.xaml (8.2 KB)

Hope helps you!

Hi @Hemant_Deshmukh,

The date the file was downloaded should match the “LastAccessTime” property. You can compare that to today’s date. Check below:

Downloaded date.xaml (8.7 KB)

Juan P.

Usually the last modified date of the file is set the download date. If that is your case, you can just compare that date with today’s date.

yourFile = "C:\Test\xyz.xlsx"

If (File.Exists(yourFile) AndAlso File.GetLastWriteTime(yourFile).Date = Today)
   ' Your automate code here
Else
  ' Skip and exit.

Thank you so much :pray: :grinning:

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