How to: turn off custom errors for debugging mode in SharePoint 2010 application pages
Unfortunately custom errors is a setting that lives at the SharePoint site level, not at the ‘application page / _layouts’ level, so you will have to edit the web.config that applies to the entire SharePoint site which is located at: C:inetpubwwwrootwssVirtualDirectories
Once there you’ll have to enable 3 different settings that should already be there for it to work:
- CustomErrors = ”Off” instead of the default which is ‘On’
- Debug=”true”. I keep hearing this might be set to false but in my case it shows true
- CallStack=”true”. Again, another value that is there for me by default but might not be in your setup.
Now remember that before making any chances you want to back up your web.config. It is a very long and delicate file and if you mess something up by accident rolling back your chances might be very hard.
In my case all I had to do is is go to the _layouts web.config and change the following line:
<customErrors mode=”RemoteOnly” />