PowerTCP Zip Compression for .NET
Encryption Enumeration
Example Example 




Enumerates the type of encryption to use or in use
Syntax
<DescriptionAttribute("Enumerate the encryption methods that Dart Zip component currently supports ")>
<CategoryAttribute("Enumeration")>
Public Enum Encryption 
   Inherits System.Enum
Dim instance As Encryption
[Description("Enumerate the encryption methods that Dart Zip component currently supports ")]
[Category("Enumeration")]
public enum Encryption : System.Enum 
[Description("Enumerate the encryption methods that Dart Zip component currently supports ")]
[Category("Enumeration")]
__value public enum Encryption : public System.Enum 
[Description("Enumerate the encryption methods that Dart Zip component currently supports ")]
[Category("Enumeration")]
public enum class Encryption : public System.Enum 
Members
MemberDescription
Aes128BitUses 128-bit AES encryption that is compatible with WinZip 9.0. As of version 1.1 this is not compatible with AES encryption in the PowerTCP Zip Compression Tool.
Aes192BitUses 192-bit AES encryption that is compatible with WinZip 9.0. As of version 1.1 this is not compatible with AES encryption in the PowerTCP Zip Compression Tool.
Aes256BitUses 256-bit AES encryption that is compatible with WinZip 9.0. As of version 1.1 this is not compatible with AES encryption in the PowerTCP Zip Compression Tool.
NoneNo encryption applied to the data.
StandardStandard zip encryption.
Example
The following example demonstrates using QuickZip and specifying specific options. Only QuickZip is required in this operation.
' Be sure to import the namespace by putting "Imports Dart.PowerTCP.Zip"
' at the top of your class.

' Preserve the path structure of the files
Archive1.PreservePath = True
	
' Include any subdirectories
Archive1.IncludeSubs = True
	
' Specify compression level
Archive1.CompressionLevel = CompressionLevel.Medium

' Use the Deflate compression method
Archive1.DefaultCompressionMethod = CompressionMethod.Deflate

' Exclude any text files
Archive1.ExcludePattern = "*.txt"

' Set to use encryption
Archive1.DefaultEncryption = Encryption.Standard

' Specify the password
Archive1.Password = "testme"

' Perform the compression operation - this is the only required method for the operation
Archive1.QuickZip("c:\\Test\\*.*", "c:\\test.zip")
// Be sure to import the namespace by putting "using Dart.PowerTCP.Zip;"
// at the top of your class.

// Preserve the path structure of the files
archive1.PreservePath = true;

// Include any subdirectories
archive1.IncludeSubs = true;
			
// Specify compression level
archive1.CompressionLevel = CompressionLevel.Medium;
			
// Use the Deflate compression method
archive1.DefaultCompressionMethod = CompressionMethod.Deflate;
			
// Exclude any text files
archive1.ExcludePattern = "*.txt";
			
// Set to use encryption
archive1.DefaultEncryption = Encryption.Standard;

// Specify the password
archive1.Password = "testme";
			
// Perform the compression operation - this is the only required method for the operation
archive1.QuickZip("c:\\Test\\*.*", "c:\\test.zip");
Inheritance Hierarchy

System.Object
   System.ValueType
      System.Enum
         Dart.PowerTCP.Zip.Encryption

See Also

Reference

Dart.PowerTCP.Zip Namespace


PowerTCP Zip for .NET Documentation Version 2.1.1
© 2018 Dart Communications. All Rights Reserved.
Send comments on this topic