C1.Xaml.Zip アセンブリ > C1.C1Zip 名前空間 > C1ZipFile クラス : Create メソッド |
'宣言 Public Sub Create( _ ByVal stream As System.IO.Stream _ )
public void Create( System.IO.Stream stream )
// ストリームに zip を作成します MemoryStream msZip = new MemoryStream(); C1ZipFile zip = new C1ZipFile(msZip, true); // それにいくつかのエントリを追加します foreach (string f in Directory.GetFiles(@"c:\WINDOWS\Web\Wallpaper")) { zip.Entries.Add(f); } // zip 形式で圧縮されたデータをバイト配列として取得します byte[] zipData = msZip.ToArray();
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