I am trying to get a list of all the site pages (with link) in a Web App or a site collection which contains custom/third-party web parts. Don't want to list out any Out-of-Box parts.

I tried ?contents=1 trick but it only lists for a single page and not for the whole site collection. Suppose, there are more than 300 Site collections. We can't go to every single page manually.

Also, I found a DB query found here

SELECT DISTINCT D.SiteID, D.WebId, W.FullURL as WebURL, D.Id As DocumentId,
                D.DirName, D.LeafName, tp_ID As WebPartSK
FROM       dbo.Docs D WITH (nolock) 
INNER JOIN dbo.Webs W WITH (nolock) ON D.WebID = W.Id
INNER JOIN dbo.WebParts WP WITH (nolock) ON D.Id = WP.tp_PageUrlID
WHERE WP.tp_ListId Is Null AND WP.tp_Type Is Null AND WP.tp_Flags Is Null
      AND WP.tp_BaseViewID Is Null AND WP.tp_DisplayName Is Null 
      AND WP.tp_Version Is Null
AND WP.tp_WebPartTypeId='<your web parts id>'

This can find where the web parts are used in a whole content DB. But it needs a Web Part Type ID. In my case, I could not find the WebPartTypeId same.

I tried with Collabion/Bamboo web parts. Wherever these webparts are used, they have different IDs.

Please help me in Listing out all Site Pages having custom/3rd party Web Parts in SharePoint 2007 Team Sites

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.