Announcing NuPack, ASP.NET MVC 3 Beta, and WebMatrix Beta 2
page 3 of 10
by Scott Guthrie
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 33248/ 100

A Simple NuPack Scenario – Enabling ELMAH

As a simple example to show off what NuPack enables – let’s assume we are working on a brand new ASP.NET application and want to use the popular open-source “ELMAH” library to log and report errors with our site.  To install ELMAH today, you’d need to manually download it, unzip it, add a reference to your project, make sure you have source control bindings for the library setup correctly, and update the web.config file of your application to include the Elmah HttpModule entries.  All doable – but a little tedious.

With NuPack installed, you can simply open the new “Package Manager Console” that NuPack enables inside VS and type “Add-Package elmah” within it:

Typing "Add-Package elmah” causes NuPack to check an online feed to locate the Elmah library, download it, add a reference of it to your current project, and automatically add the appropriate Elmah registration entries within your application’s web.config file:

And now we have Elmah setup and installed for our project, and error report logging enabled.  No additional manual steps required to make it work.

View Entire Article

User Comments

No comments posted yet.

Product Spotlight
Product Spotlight 

Community Advice: ASP | SQL | XML | Regular Expressions | Windows

©Copyright 1998-2024  |  Page Processed at 2024-05-23 2:13:59 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search