Jan 12 2006

Visual Studio .NET and Class Libraries

Category: ASP.NET 1.x | ASP.NET 2.0 - GeneralBil@l @ 04:31

When I start a new project, I usually create a Blank Solution in VS.NET, then add to it my Class Libraries and Web Application. The problem I used to have before is that, every time I did some changes in one of the Class Libraries I had to update the references manually to all other projects referencing that updated Class Libraries.

Thank to Peter Johnson for hinting for me that:

Correct way:
1. Right-click web project file, choose "Add Reference..."
2. Click "Projects" tab.
3. Select your class library project and hit OK.

Wrong way:
1. Right-click web project file, choose "Add Reference..."
2. On ".NET" or "Browse" or "Recent" tabs, choose your class library output DLL.

Hope that helps you out.

This way, whenever you change anything in your Class Libraries, then you do a Build, all the references will be updated.

Regards

 

Tags: ,

Comments are closed