How create a folder for every 2 files located in a specific directory ,using for each

hi everyone,

Will there be a way to create a folder for every 2 files located in a specific directory using for each?, its necessary use this sentence or you recommend another way to do that?

hi @Rodrigo.Hernandez,

Welcome to the Uipath Community !

On what basis the Folder should be created ? Any Criteria’s .

Also , If you just want to Create Folder as per Files : I have created a Bot for that - Have a look at Below video where Bot is Creating Folder as per Files.

If you need Assistance on below - Happy to Help :slight_smile:

–
Mukesh

hi thanks for the response but sorry i cant watch the video the link must be corrupted.

i want to create a folder by every 2 files inside them to before move it to that folder that´’s the idea, i already have made an assign activity in “FacturasDiarias” with System.io.Directory.GetFiles("\DirectiryFolder"+“Factura”+"_"+Fecha)

FacturasDiarias is an Array String and in that folder must be 6 files i think if i made a for each 2 files inside “FacturasDiarias” must create a folder in the next activity but when i run it only made me one.

@mukeshkala
can you share .Xaml File ?

Hello,

You can try something like

folder = ""

For Each item in FacturasDiarias // use i as counter in the properties

    If  i % 2 = 0
        folder = ...
        CreateFolder

    etc.
1 Like

hi @Anand_Designer,

I have published the component to Uipath marketplace.

Please follow the below link to leverage the same.

–
Mukesh