how to know File Is Corrupted or Passoword Protected

Aug 9, 2013 at 6:37 AM
Hi ,

Actually I wanted to know if there any error message or anything by which we can know whether file is Password Protected or Corrupted Zip File.

When we check using SevenZipExtractor.Check at that time.

Thanks,
Naitik
Sep 27, 2013 at 8:31 AM
to check for password protection, a little code snippet
SevenZipExtractor engine = new SevenZipExtractor(fileName);

if( engine.Password != null )
{
     MessageBox.Show("Archive is Password Protected");
}