Question

Sort Files in subfolders by modified date - Get File Date

  • 9 November 2022
  • 6 replies
  • 1255 views

Hello, I have a Folder with a lot of files, I need to build a bot to:

check each file modified date, and move to a sub folder like yyyy\mm\

 

I was thinking in make a Loop for each file iin folder, and some function to read file modified date, but there is no native function to read it.

 

How can I do it?

 


6 replies

Userlevel 6
Badge +16

Hi @Aldo Lanfranconi​ ,

 

Checkout below botstore bot to get 'file modified date'

 

https://botstore.automationanywhere.com/bot/file-and-folder-attributes-package/p>

Hello Chandu, on the package you mention there are 7 .JAR package files to import:

 

bot-command-browser-3.0.0-20210505-201256.jar

bot-command-file-4.0.0-20210504-152837.jar

bot-command-folder-4.0.0-20210504-152839.jar

bot-command-messagebox-3.0.0-20210504-152941.jar

bot-command-step-2.0.2-20210504-153452.jar

FileFolderAttributes-2.1.0-20211018-153636.jar

JavaFX-2.4.0-20200426-215144.jar

 

the only one it seems to be related is bot-command-file

After importing, there is no new file command action to get file modified date.

 

what am I doing wrong?

Captura de pantalla 2022-11-09 114341 

Userlevel 3
Badge +6

Import : FileFolderAttributes-2.1.0-20211018-153636.jar and check new actions

Excellent, It works!

Userlevel 6
Badge +16

Hi @Aldo Lanfranconi​ ,

 

Checkout below tutorial for downloading the package offline and upload back to CR

 

https://www.youtube.com/watch?v=5C-SYRt9sd8/p>

 

Checkout below tutorial on usage of "File and Folder Attributes: File Attributes" command to get Last modified date. Time Stamp : 8:42

 

https://www.youtube.com/watch?v=FqTXD8v9eY0/p>

Badge +1

hi i am using file folder trigger to run the bot .when new file is added in folder bot has trigger and read newly added xml file .but somtimes two or more files are added in the folder (if 5 files added at same time the bot is triggered 5 times but it reads only same file each time .I need read those 5 files one bye one) how i overcome this problem .

(Note: latest file is comes at first index always)

 

Reply