This project is read-only.
1
Vote

Exception when casting Webpart

description

In the current code, when webparts are scanned (method ScanWebParts in SiteLinkChecker), they are casted to Microsoft.SharePoint.WebPartPages.Webpart. This means that webparts inheriting from System.Web.UI.WebControls.WebParts.WebPart probably would get a casting error.
 
the row
foreach (WebPart wp in wpm.WebParts)
 
should be changed to
foreach (System.Web.UI.WebControls.WebParts.WebPart wp in wpm.WebParts)

comments