I have created a Web Part which reads and parses the SharePoint logs in order to display usage information of the page it resides on.ÃÂ The Web Part works perfectly on the top page, reading and displaying the information desired.ÃÂ However, once the Web Part is added to any page lower in the site heirarchy (sub-page) the same Web Part throws the following error:
Web Part Error: A Web Part or Web Form Control on this Page cannot be displayed or imported. The type could not be found or it is not registered as safe.
Show Error Details
Hide Error Details
[UnsafeControlException: A Web Part or Web Form Control on this Page cannot be displayed or imported. The type could not be found or it is not registered as safe.]
ÃÂ at Microsoft.SharePoint.ApplicationRuntime.SafeControls.GetTypeFromGuid(Guid guid)
ÃÂ at Microsoft.SharePoint.WebPartPages.SPWebPartManager.CreateWebPartsFromRowSetData(Boolean onlyInitializeClosedWebParts)ÃÂ
Of course the current version of the Web Part is in the SafeControls list on the web.config.
The Web Part was originally designed to return site activity only for the top default.aspx page and worked fine but started to fail in the manner described above once I added the following line of code to return a SPCo
View Complete Post