I am zipping a directory in C# using ZipFile.CreateFromDirectory method:
private void createZIP()
{
string startPath = @"c:\example\start";
string zipPath = @"c:\example\result.zip";
ZipFile.CreateFromDirectory(startPath, zipPath, CompressionLevel.Fastest, true);
}
It's working in general, but I just want the content of the /start/ folder in the zip file, not the directory itself.
Now:
result.zip
--start
---- file1.txt
---- file2.txt
How I want it:
result.zip
-- file1.txt
-- file2.txt
How can I achieve this?