Webpart registration error in event log
We created several custom web parts for SharePoint 2007. They work fine. However whenever they are loaded, we get an error in the event log saying:
error initializing safe control - Assembly: ...
The assembly actually loads fine. Additionally, it is correctly listed in the
Any ideas about how to stop these (Phantom?) errors would be appreciated.
You need to add a safecontrol entry to the web,config file, have a look at the following:
<SafeControls> <SafeControl Assembly = "Text" Namespace = "Text" Safe = "TRUE" | "FALSE" TypeName = "Text"/> ... </SafeControls>
Read more... Read less...
I was having this problem too. It turned out that there was a problem with my Manifest.xml file. In the SafeControl tag for my assembly, I had the TypeName specifically defined. When I changed the TypeName to a wildcard value, the error messages in the event log stopped.
So to recap: This caused errors in the event log:
<SafeControl Assembly="AssemblyName, Version=18.104.22.168, Culture=neutral, PublicKeyToken=5bac12230d2e4a0a" Namespace="AssemblyName" **TypeName="AssemblyName"** Safe="True" />
This cleared them up:
<SafeControl Assembly="AssemblyName, Version=22.214.171.124, Culture=neutral, PublicKeyToken=5bac12230d2e4a0a" Namespace="AssemblyName" **TypeName="*"** Safe="True" />
It sure does sound like you have a problem with your safe control entry. I would try:
Under the NameSpace and TypeName use "*". Using wildcards in namespace and typeName will register all classes in all namespaces in your assembly as safe. (You generally wouldn't want to do this with 3rd party tools.)
This is because of the amount of list items in the lists. Your server takes to much time to migrate all the list items and it fails, try deleiting the list items or configuring the server.