尝试在 SharePoint 网站中编辑页面时出现错误。使用 WinDbg 我看到实际错误是:
Microsoft.SharePoint.ApplicationRuntime.SafeControls+UnsafeControlException
这在我看来就像我在页面上有一个控件,它不包含在 web.config 的 <SafeControls> 部分中。我查看了该页面的 aspx 文件,但在 web.config 中看不到任何没有引用的控件。
深入挖掘(并使用Sosex.dll)我从导致错误的调用堆栈中获得了以下数据:
0:013> !mframe 03
0:013> !mdv
Frame 0x3: (Microsoft.SharePoint.ApplicationRuntime.SafeControls.GetTypeFromGuid(System.Guid)):
[A0]:this:0xc00c03e8 (Microsoft.SharePoint.ApplicationRuntime.SafeControls)
[A1]:guid:{ef2d8253-a451-56da-be1d-5f32d5227173} VALTYPE (MT=0000064278430ea8, ADDR=000000000308caa0) (System.Guid)
[L0]:null (System.Type)
[L1]:0x633c50 (System.String) STRVAL=The type could not be found or it is not registered as safe.
[L2]:null (System.Type)
所以看起来我找到了导致问题的控件 ([A1]) 的 GUID。但是,我不知道如何找到此 GUID 引用的控件。SQL Server 中的某处必须有一个存储此信息的表?我已经尝试过 dbo.WebParts,使用 GUID 选择 tp_ID,但它什么也没找到。我想我错过了什么?