Skip to content

Don’t trust SharePoint error messages

July 6, 2006

The following post was retrieved from: http://vspug.com/kwanl/2006/07/06/don-t-trust-sharepoint-error-messages/

Recently we’ve been trying to automate the provisioning of web part pages that require many customized web parts. Because of design issues we decided to do this from a ASPX page in the _layouts folder.

Things we going smoothly until we started getting the dreaded “not registered as safe” errors when trying to add our web parts. That was not the case because the web parts were installed and running. Through some experimentation, we discovered that it worked if the web parts were in the GAC. Combining the confusing error message and this new information would lead you to believe that you’re dealing with a security issue. That is not the case.

The real problem was that the web part assemblies could not be located by the ASPX page in _layouts. So it was really an assembling binding error.

Solution: Use a web service to add the web parts to the web part page.

Daniel Larson ran into a similar problem:

http://www.portalbuilder.org/sites/daniellarson/blog/Log/DisplayLog.aspx?ID=30

Advertisements
Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: