Chilkat HOME Android™ ASP Visual Basic VB.NET C# iOS (IPhone) Objective-C C++ C Unicode C++ Unicode C MFC Delphi DLL Delphi ActiveX FoxPro Java Perl PHP Extension PHP ActiveX Python PowerShell Ruby SQL Server VBScript
BZIP2 Compress Byte Array to Base64-Encoded Compressed StringDownload: Chilkat .NET Assemblies C# code showing how BZIP2 compress a byte array and return the result as a Base64-encoded compressed string. // Generate some data to be BZIP2 compressed. byte[] inputByteData = new byte[1000]; int i; for (i=0; i<1000; i++) inputByteData[i] = (byte)(i%100); // Create an instance of the Chilkat encryption class. Chilkat.Crypt2 crypt = new Chilkat.Crypt2(); // Any code begins the 30-day trial. crypt.UnlockComponent("30-day-trial"); // Indicate that we want Base-64 output. crypt.EncodingMode = "base64"; // BZIP2 compress the data, returning the resulting // compressed binary data as a base64-encoded string. MessageBox.Show(crypt.CompressBytesENC(inputByteData)); Important: The download for this
example does not contain the ChilkatDotNet.dll which |
© 2000-2013 Chilkat Software, Inc. All Rights Reserved.