Hello i have a function that moves all files inside several subfolder into another folder. But i want to make a function that excludes a certaint folder and instead of moving all the files in that particular folder, instead delete all the files within it ( but still keep the folder) then for the other subfolder move them to designated destination
Does using the delete activity help you?
Yes, but shall i insert a if statement? saying if the subfolder contains this title then delete all files within it else move them?
Need a function that says if files are in folder “test” then delete them else proceed with else statement
You can use
Directory.GetFiles(selectFolder) To get the names
in the if statement
using delete and move to else.
see if that helps
otherwise try to better explain the condition of moving, I did not understand very well lol
currently i am going thorugh all my subfolders in a folder. from there i go trough all the files in those subfolders. want to move all files in every subfolder but exclude a specific subfolder “testfolder” and instead delete those files inside that folder
Can you attach your project?
Main.xaml (12.5 KB)
See if that helps.
I changed the project path.
And in the IF statement put the folder name in “”
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.