Monthly Archives: May 2011

How to enable the SharePoint Stack Trace

Sometimes SharePoint can be a little bit of a pain as it gives you a nice generic error message like “Unexpected Error occurred“, but it won’t give you any clue what’s actually going on. Of course you already checked the SharePoint Trace Logs with or without the help of our friendly neighborhood ULS viewer. But there’s another clue you can reveal, The Stack Trace.

 Steps

  1. Go to the web.config of the site that gives you the error (somewhere in C:\inetpub\…….).
  2. Make a copy of the web.config and start editing the original.
  3. Use Ctrl + F to search for SafeMode MaxControls and change the word false in to true.<SafeMode MaxControls=”200″ CallStack=”true” DirectFileDependencies=”10″ TotalFileDependencies=”50″ AllowPageLevelTrace=”false”>
  4. Use Ctrl + F again to search for customErrors and change the word On in to Off.
  5. Safe the web.config and do an iisreset /noforce.
  6. Reproduce the error and try solving the nice ASP error you received.

 

Example of a nice generic SharePoint Error

Example of a ASP error whit the Stack Trace enabled