Archive for May, 2009
Documenting C# code with XML Comments
This article explains an easy and effective way of documenting your C# code. XML comments are the solution for generating a clean documentation for your code. Visual Studio environment allows you to generate a documentation file for your project. It helps your teammates and other people who using your code.
This post will explain how to use XML comments in code and how to generate XML help documents from those comments.
XML Comment Basics
XML comments can be used to all types except namespaces. The types can be Class,Module,Interface, Enum, properties, events and methods.
XML comments are inserted inline, directly in your source code. To insert an XML comment type three single “///” immediately above definition.
Related Posts:
No commentsGAC in .NET Framework
The Global Assembly Cache known as the GAC is to enable sharing of assemblies across several managed applications installed on a machine. All managed developers can install assemblies to the GAC and share them across applications.
When to Use the GAC
When should an assembly be installed in the GAC as opposed to assembly in application base? If you have any assembly that must be shared across multiple applications and hence centrally serviced. Shared frameworks and components typically fall under this category.
It is a machinewide repository of managed assemblies.
When shouldn’t an assembly be placed in the GAC? If you need the application to be xcopy deployable on different machines, placing the assembly in the GAC is probably not best idea. In this case the assemblies in the GAC will also need to be moved across machines.
Binder follows the “GAC always wins” policy.
GACUtil is a tool used to install, uninstall the assemblies to and from the GAC.
This tool ship with .NET Framework SDK. In .NET Framework 4.0, the GAC went through a few changes. The GAC was split into two, one for each CLR.
The CLR version used for both .NET Framework 2.0 and .NET Framework 3.5 is CLR 2.0. There was no need in the previous two framework releases to split GAC. The problem of breaking older applications in Net Framework 4.0.
To avoid issues between CLR 2.0 and CLR 4.0 , the GAC is now split into private GAC’s for each runtime.The main change is that CLR v2.0 applications now cannot see CLR v4.0 assemblies in the GAC.
Related Posts:
No commentsAssembly binding in .NET Framework
The CLR is responsible for locating and binding the assemblies in the code. In Order to work assembly binding efficiently you need to follow some best practices.
Assembly Naming
Always use fully specified assembly names. An assembly name is a name given to unique identity. Two assemblies representing the same identity can have the same name with different versions.
Assemblies are mostly loaded by it’s name and keeping the names consist makes it easier for the loader to find the assembly. A fully qualified assembly consist of four fields:
- Name of the assembly
- The version
- The culture
- The public key token
Partial Binding
Related Posts:
No comments.NET Access Control Service
My previous article explained the basics of building windows azure services. Let’s start looking at the .NET Access Control Service. .NET Access Control Service allows you to use the authentication and authorization services from external sources that are maintained by security experts. Security experts control the authentication and issue the token to the application. Application just uses those tokens by avoiding the authentication process.
Related Posts:
No commentsVisual Studio 2010 Beta 1 and .NET FW 4.0 Beta 1 Released!
Yesterday Visual Studio 2010 Beta1 and .NET FW 4.0 Beta 1 was released and you can download it from here. Download Beta 1.
More about Highlights in VS 2010 Beta1 can found in Jason Blog.
Enhancements in ASP.NET and discussions on latest version here
Feedback, Questions related to VS 2010 can be found here
Next posts I am going to discuss more on the highlights in VS 2010
Related Posts:
No commentsBuilding Windows Azure Services
Introduction
Microsoft introduced cloud platform officially known as Azure Services Platform.It makes easy for .NET Developers to move their applications to the cloud using same tools and API’s they’re already familiar with. It provides highly-scalable execution environment for running .NET Applications and storing data in Microsoft data centers throughout the world.
Related Posts:
No comments


![Recommend [kalyanms1]](http://s3.amazonaws.com/arkayne-media/img/badge/logo-recommend-badge-medium.png)