Visual CSharp .NET - comprimir carpeta

 
Vista:
sin imagen de perfil

comprimir carpeta

Publicado por alexis (59 intervenciones) el 14/08/2012 00:36:47
buenas tardes que tal, estoy intentando comprimir una carpeta en visual studio 2008, en c #

busque en internet y corri este ejemplo en .net 2010 y me funciono


1
2
3
4
5
6
7
8
9
10
using ICSharpCode.SharpZipLib.Core;
using ICSharpCode.SharpZipLib.Zip;
 
  ComprimirZipFast();
 
   static void ComprimirZipFast()
        {
            FastZip fZip = new FastZip();
            fZip.CreateZip("C:\\Generado\\Generado.zip", "C:\\Generado", false, ".txt$");
        }

e probado la funcion como public o static, tambien prove con la version de framework 2. version 3 y version 3.5

en el 2010 comprime bien , en el 2008 me sale el siguiente error

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> System.IO.FileNotFoundException: Could not load file or assembly 'ICSharpCode.SharpZipLib, Version=0.86.0.518, Culture=neutral,
PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
File name: 'ICSharpCode.SharpZipLib, Version=0.86.0.518, Culture=neutral, PublicKeyToken=null'
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder