Can you extract on a wildcard?
I can see that you can when zipping up files? I will not know the name of the files within the zipped folder, however the type will always be .png and there will only ever be one png file.
i.e.
using (var ms = new MemoryStream())
{
var entry = zipout["*.png"];
if (entry != null)
{
entry.Extract(ms);
}
else
{
return;
}
}
using (var zipout = ZipFile.Read(stream))
{
using (var ms = new MemoryStream())
{
foreach (var e in zipout.Where(e => e.FileName.Contains(".png")))
{
e.Extract(ms);
}
}
}