Net Encryption Library
DecompressFile Method
Example 






KellermanSoftware.NetEncryptionLibrary Namespace > Encryption Class : DecompressFile Method
Decompress a file using the specified compression type
Syntax
'Declaration
 
Public Sub DecompressFile( _
   ByVal compressionType As CompressionType, _
   ByVal inputFilePath As System.String, _
   ByVal outputFilePath As System.String _
) 
'Usage
 
Dim instance As Encryption
Dim compressionType As CompressionType
Dim inputFilePath As System.String
Dim outputFilePath As System.String
 
instance.DecompressFile(compressionType, inputFilePath, outputFilePath)
public void DecompressFile( 
   CompressionType compressionType,
   System.string inputFilePath,
   System.string outputFilePath
)
public procedure DecompressFile( 
    compressionType: CompressionType;
    inputFilePath: System.String;
    outputFilePath: System.String
); 
public function DecompressFile( 
   compressionType : CompressionType,
   inputFilePath : System.String,
   outputFilePath : System.String
);
public: void DecompressFile( 
   CompressionType compressionType,
   System.string* inputFilePath,
   System.string* outputFilePath
) 
public:
void DecompressFile( 
   CompressionType compressionType,
   System.String^ inputFilePath,
   System.String^ outputFilePath
) 

Parameters

compressionType
inputFilePath
outputFilePath
Example
Encryption encryption = new Encryption(); //Trial Mode
//Encryption encryption = new Encryption("place user name here", "place license key here"); //License Mode
 
StringBuilder sb = new StringBuilder();
for (int i = 0; i < 1024; i++)
    sb.AppendLine("This is a test");
 
File.WriteAllText("input.txt", sb.ToString());
 
encryption.CompressFile(CompressionType.MiniLZO, "input.txt", "compressed.txt");
encryption.DecompressFile(CompressionType.MiniLZO, "compressed.txt", "decompressed.txt");
Dim encryption As New Encryption() 'Trial Mode
'Dim encryption As New Encryption("place user name here", "place license key here") 'License Mode
 
Dim sb As New StringBuilder()
For i As Integer = 0 To 1023
    sb.AppendLine("This is a test")
Next i
 
File.WriteAllText("input.txt", sb.ToString())
 
encryption.CompressFile(CompressionType.MiniLZO, "input.txt", "compressed.txt")
encryption.DecompressFile(CompressionType.MiniLZO, "compressed.txt", "decompressed.txt")
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

Encryption Class
Encryption Members