Enable debugging for SharePoint 2010

I. Virtual Directory Web.Config File

  • Locate and open the “Web.Config” file . (Usually located at : “C:\Inetpub\wwwroot\wss\VirtualDirectoties\<port_number_of_Web application>”) .
  •  Search and find the line of code (below) and change the “debug” attribute to “true” and then save the changes :
    <compilation batch=”false” debug=”false”>   into <compilation batch=”false” debug=”true”>
  •  Search and find the following line of code and change the “CallStack” attribute to “true” and then save the changes :
    <SafeMode MaxControls=”200″ CallStack=”false” …>   into <SafeMode MaxControls=”200″ CallStack=”true”…>
  • Search and find the following line of code and change the “mode” attribute to “Off” and then save the changes:
    <customErrors mode=”On” /> into <customErrors mode=”Off” />

II. “LAYOUTS Web.Config File”:

  •  Locate and open the LAYOUTS “Web.Config” file . (Usually located at : “C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\Template\Layouts”) .
  •  Search and find the following line of code and change the “mode” attribute to “Off” and then save the changes:
    <customErrors mode=”On” /> into <customErrors mode=”Off” />

Source: http://www.mssharepointtips.com/tip.asp?id=1115

Leave a comment