Upload zip file but not ending with _AR.zip

Hi,

I have to upload zip files to particular folders on a webpage:
For example:
File “2222_ENQ_ EE_CCC.zip” needs to be uploaded in folder 1
File “333_ENQ _ EE_CCC_AR.zip” needs to be uploaded in folder 2
File “444_FV_DD_PPP.zip” needs to be uploaded in folder 3
File “555 _ FV_DD_PPP _ AR.zip” needs to be uploaded in folder 4

How do i say:

  • if file contains ENQ and AR then folder 2
  • if file contains ENQ and no AR then folder 1

Thanks in advance,
Kind regards

You might be getting all the files and iterating via a for each loop on each file like this -

image

You can have file name in same loop like FileName = Path.GetFileName(“File From Loop”)

then you can have condition to filter your path if FileName.Contains(“_AR”) then upload to folder 1 and so on

1 Like

Thanks, got me in the right direction.
Was thinking in another way.