Dot Net Mafia

Group site for developer blogs dealing with (usually) Ionic, .NET, SharePoint, Office 365, Mobile Development, and other Microsoft products, as well as some discussion of general programming related concepts.

This Blog



Corey Roth [MVP]

A SharePoint MVP bringing you the latest time saving tips for Ionic, SharePoint, and Office 365.

Compilation Error with Generic Handler in Visual Studio 2008

Anyone else out there notice that if you add an generic handler to your project that it won’t compile?  It appears to be an issue with the template included in Visual Studio and it may have been resolved in a service pack but currently I don’t think so.  The file type I am describing is the .ashx generic handler and not the ASP.NET Handler as you can see below.


After it creates the file you might immediately notice there are issues.  If you go to compile it, you’ll get errors like seen below.


Luckily, resolving the error is quite easy.  You just need to add System.Web.Services to your using block.  Once you do that, you can compile successfully and begin building your handler.  I just thought I would point this out since I have seen this on multiple systems now.



Twitted by coreyroth said:

Pingback from  Twitted by coreyroth

July 27, 2009 6:00 PM

Leave a Comment


About CoreyRoth

Corey Roth is an independent SharePoint consultant specializing in ECM, Apps, and Search.
2018 dotnetmafia.
Powered by Community Server (Non-Commercial Edition), by Telligent Systems