How to zip files with a certain extension and then delete those files

Hi @Ishan_Shelke

First, you can create list of all files from your directory by using Directory.GetFiles method by:

Directory.GetFiles(strPathToFolderWithFiles, "*.xls").ToList()

Then, having those files saved in a list, you can create a separate folder and move all those files from the first folder, to the newly created one.

In the end, in order to create final .zip file, you can follow the following steps: