How to delete the all the files in a folder in one line

Hi.I want to delete all the files in a specific folder in one line code with out using any for loop.Can anyone help me

3 Likes

you can delete the folder using delete activity and recreate the directory in the same place using create directory activity

1 Like

I don’t want to delete the folder.I want only the files to be deleted in the folder.Is it possible with out for each activity

go through this post

2 Likes

For this line,I’m getting the validation error like 'Argument not specified for parameter ‘path’ of 'Public shared Sub Delete (path as String)

hey @sandhyak9

Use below sample: - Delete All files INside a directory.xaml (5.7 KB)

Regards…!!
Aksh

24 Likes

Hey aksh1yadav,

It is working fine.Thank you so much

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.