Navigation

Search

Categories

On this page

Archive

Blogroll

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

RSS 2.0 | Atom 1.0 | CDF

Send mail to the author(s) E-mail

Total Posts: 125
This Year: 63
This Month: 0
This Week: 0
Comments: 0

Sign In

 Thursday, July 24, 2008
Thursday, July 24, 2008 8:59:09 PM (Eastern Standard Time, UTC-05:00) ( )

I've been learning how to develop parts for WSS 3.0 and have found that debugging them is a real pain.  I picked up this tip from SharePoint Development and Programming FAQ which has proven helpful.

Problem

You receive “The "yourWebPartName" Web Part appears to be causing a problem” or a generic error message when developing a web part.

Cause

Exceptions are caught by SharePoint and a friendly error message is displayed instead of a stack trace.

Resolution

To configure SharePoint to display the full exception needed for debugging make the following changes to your SharePoint site’s web.config file (typically located in \Inetpub\wwwroot\wss\VirtualDirectories\yoursite).

· Find: <SafeMode CallStack="false" />

· Replace with: <SafeMode CallStack="true" />

· Find: <customErrors mode="On" />

· Replace with: <customErrors mode="Off" />

· Find: <compilation debug="false" />

· Replace with: <compilation debug="true" />

Name
E-mail
Home page

Comment (HTML not allowed)  

Enter the code shown (prevents robots):