SYSK 84: Where Do GAC Assemblies Live?

Ever wondered where shared assemblies actually are stored, and how “side-by-side” is made possible?  Well, the secret is about to be revealed….   Ok, so it’s somewhere in the file system…  But where exactly?   You’ll need to open the console command prompt (Start -> Run -> cmd -> Ok) – Windows Explorer won’t let…

2

SYSK 83: On the Importance of Calling TrimToSize

Like StringBuilder (see SYSK 16), ArrayList, Queue and SortedList double the buffer when the existing capacity is exceeded and a new element must be inserted.  Try it for yourself – create an ArrayList and call its Capacity property.  By default, it initializes itself to 16 elements, so you should get 16.  Add 17 items, and…

2

SYSK 82: Compression Example in .NET

As many of you may know, .NET framework 2.0 contains a built in support for compressing the file or any generic stream such as FileStream, MemoryStream, TextWriter, XmlWriter, NetworkStream, etc   So, now, you can compress/decompress using GZip algorithm natively in .NET.  The code below is an example of compressing/decompressing a file.  To run it,…

7