0 votes
1 view
in RPA by (12.8k points)
Hi, I download files from a website, the problem is every time I download the files names get updated and I don't want it. Is there a  way I can automate deleting the previously downloaded files ?

1 Answer

0 votes
by (29.8k points)
Hi, yes there is an easy way to do that just follow the steps given below

1) Use the method Directory.GetFiles()

2) provide the path of the directory where your files are saved

3) the above will return an array of files, you can apply a for each loop and delete them all

Related questions

0 votes
1 answer
0 votes
0 answers
0 votes
0 answers
Welcome to Intellipaat Community. Get your technical queries answered by top developers !


Categories

...