I was searching today on "zipping" up files via C#. I Googled and found nothing relating to the .NET framework. I remembered there being something in the framework. I tried searching for "C# msdn zip" and found nothing. Using the F1 key in Visual Studio, my search finally came around to the System.IO.Compression namespace. Of course this namespace does not deal directly with .zip files. That got me thinking; do I want a zip file, or do I want just plain compression. In the case of the project I'm working on, just plain accurate compression is what I was after. Some features are missing (password protect), but I could extend the class if necessary. I wanted to stay with functionality built into the framework for this project, so I am glad that I was persistent. I am disappointed that this namespace isn't more obvious when searching for C# and zip.
Many times if you look hard enough, you can find what you really want.
I was tasked today to move our build box from one machine to another. This seemed like a trivial task and I approached it as such. We are using NAnt, NAntContrib, NUnit, WiX, and a few other custom components to do the full build. I had both machines up via Remote Desktop. The original machine was working perfectly, but the new machine was giving me the following error:
Failure executing test(s). If you assembly is not built using NUnit version 22.214.171.124, then ensure you have redirected assembly bindings. Consult the documentation of the <nunit2> task for more information.
Could not load file or assembly 'nunit.framework, Version=126.96.36.199, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77' or one of its dependencies. The system cannot find the file specified.
After looking at the error, I still couldn't figure it out. I Googled the error and didn't find anything particularly helpful. I re-ran the NUnit installer and it still didn't fix the issue. So to make a long story short, I found that the nunit.framework.dll was not registered in the GAC. So if you come across this issue or a similiar issue, check out the GAC and make sure the file is there. The MSI for NUnit didn't do it for me...
Last Visit: 31-Dec-99 18:00 Last Update: 27-May-17 4:59