Debugging a HTTP Handler RRS feed

  • Question

  • User8638317 posted



                I am trying to debug a HTTP Handler in Visual Studio and the break point is not getting hit. Does anyone have an idea on how to go about debugging HTTP Handlers in Visual Studio?


                I am using VS 2010 Premium, .net 4.0 on a Windows 7 machine. In my Web Application I have a HTTP Handler in /HTTPHandler/TrackingHandler.cs

     The following is in my web config file:

                <add name="TrackingHandler" path="/tx/*" verb="*" type="ProjectNamespace.TrackingHandler" resourceType="Unspecified" preCondition="integratedMode" />

    My tracker looks like below

    namespace ProjectNamespace
        public class TrackingHandler : IHttpHandler
            public bool IsReusable
                get { return true; }
            public void ProcessRequest(HttpContext context)
                 //Breakpoint on the very first line below
                 string tracker = Path.GetFileName(context.Request.PhysicalPath);

    I start my Web Application using any random page in Visual Studio Debug. I then maually edit the URL to point to the /tx/ directory and some random string after it. For e.g. my current URL looks like http://localhost:53699/tx/sdfs. I thought this should pull up the breakpoint on the first line of  ProcessRequest() but it does not. 


    I’d be grateful for any ideas.

    O. O.

    Friday, June 15, 2012 5:41 PM

All replies

  • User1320044578 posted

    Are you getting any error?

    Are you created dll for handler ?

    in type there dll name must be specified.

    Thursday, July 18, 2013 9:31 AM