In the previous article Use a custom categorySharpzipRunZipCompression and decompression(VB. NET) Meow Sharpzip We made a package to make it more intuitive to use. Meow thought that if he could write COM + Component, you can ASP Or VB Call usage, more available.
ConvertCOM +Requires some additional settings, which is similarCOM +The component is written in the same way. For details, refer to this article:
N-tiers Development Method ( How to Use VB. NET Write COM + Components )
N-tiersDevelopment Method(COM +Component registration and Modification)
However, meow encounters a situation where the following error message appears when the registered component is called for use.
Unable to load files or components'Icsharpcode. sharpziplib, version = 0.85.4.369, culture = neutral, publickeytoken = 1b03e6acf1164f73'Or one of their dependencies. The system cannot find the specified file.
The reason is that Icsharpcode. sharpziplib. dll Not registered to the system, so when I write COM + To call this DLL You can't find it.
Therefore, you must OS Put this DLL Register. Because DLL Not COM + Of DLL , So use the following method to register
Enable Visual Studio 2005 Command Prompt characters (Vs2005 To install SDK Yes ) Then Icsharpcode. sharpziplib. dll Copy to a storage DLL And then enter the following two commands:
Regasm/TLB icsharpcode. sharpziplib. dll
Gacutil/I icsharpcode. sharpziplib. dll
This will DLL Generate TLB And register GAC . COM + You can call DLL And perform Compression / Decompressed.
After meow testing ASP In COM + Correct Compression / Decompress the file. In this way COM + Let ASP/ASP. NET/Vb/VB. NET All these systems can be compressed. / Decompression capability.