Create a .bat file in each project folder

Hello friends, I would like to create a .bat file in each project found in the path
C: \ Users \ XXXXXXXX \ Documents \ UiPath \

The tricky thing is that there are subfolders that contain projects.
My question is, how to create that file also in the subfolders in the robot execution.

For example
the run.bat file has to be in
projectWork1
projectWork2
projectExcel1
projectExcel2
projectExcel3
C: \ Users \ XXXXXXXX \ Documents \ UiPath \ projectWork1
C: \ Users \ XXXXXXXX \ Documents \ UiPath \ projectWork2
C: \ Users \ XXXXXXXX \ Documents \ UiPath \ WorkExcel \ projectExcel1
C: \ Users \ XXXXXXXX \ Documents \ UiPath \ WorkExcel \ projectExcel2
C: \ Users \ XXXXXXXX \ Documents \ UiPath \ WorkExcel \ projectExcel3
.
.
.

@Enrique.ts

Save your file paths in a excel sheet

Use ForEach activity and copy file activity

Check below for your reference

Hope this may helps you

Thanks

You can use the code:

Directory.GetFiles(directory, "*.*", SearchOption.AllDirectories).ToList()

2 Likes