title: Debugging a User Control from ASP.NET
body: <p>I have an ASP.NET (2.0) site. I am on my dev box using V Studio 2008 and IIS. I have a separate User Control project that gets called from a javascript function in the default.aspx page. The User Control project is in another solution.</p>
  
  <p>The application is running as expected. The user control is being called and all is well. Well not quite.</p>
  
  <p><strong>I am unable to step into the User Control project, i.e debug it.</strong> I can set breakpoints but they never get trapped. I can debug all other areas of the site both in script and code behind without any problems. The User control gets built in DEBUG to the same location as the default.aspx page.</p>
  
  <p>Things i have already tried:
  Enabled script debugging in IE.
  Added the User Control project to the same web site solution
  Attached debugger to running instance of IE from Visual Studio
  Enabled debugging on the site.
  Built the user control in debug mode and ensured the pdb is in the same directory</p>
  
  <p>Below is some sample code which should help:</p>
  
  <p>default.aspx: (Cut down for brevity)</p>
  
  <p></p>
  
  <p>
              
              
              
          </p>
  
  <p>
          function LoadMethod()
          {
              try
              {
                  LoadControl.Ping();  </p>
  
  <pre><code>        }
          catch (e) //if the DLL didn't run assume there is a trust problem.
          {    
          }
      }
  </code></pre>
  
  <p>When i go to step into the call to LoadControl.Ping, the debugger just steps over this line of code.</p>
  
  <p>Please only give feedback if you have actually done this in practice. </p>