Ask a questionAsk a question
 

AnswerContent Query Web Part Error

  • Monday, February 11, 2008 8:28 AMfreddeb0y Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Hi,

    I get the following error when i try to add a ContentByQuery.webpart using SharePoint Server 2007:

     

    "Unable to display this Web Part. To troubleshoot the problem, open this Web page in a Windows SharePoint Services-compatible HTML editor such as Microsoft Office SharePoint Designer. If the problem persists, contact your Web server administrator."

     

    I've seen a lot of people having this problem when they aren't on an admin account, but I am, and this error happens before I can do any configuration at all to the webpart.

     

    The webpart didn't show up in the webpart list at first, so I added it from the webparts gallery. The actual name of the part is Microsoft.SharePoint.Publishing.WebControls.ContentByQueryWebPart.

    Is this the wrong kind of webpart or what seems to be the problem? I don't have much experience in Sharepoint since before, as you might can tell.

    Help would be VERY appreciated, thanks in advance.

Answers

  • Monday, February 11, 2008 12:03 PMWaldek MastykarzMVPUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Content Query Web Part ships as a part of the Publishing Feature. Next to the WebPart itself, the Publishing Feature contains various resources required by the CQWP, like ItemStyle.xsl which contains the presentation layer of CQWP. Because you have added the WebPart manually you're missing these resources what leads to the error you see. Activating the Publishing Feature should solve your problem.

All Replies

  • Monday, February 11, 2008 12:03 PMWaldek MastykarzMVPUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Content Query Web Part ships as a part of the Publishing Feature. Next to the WebPart itself, the Publishing Feature contains various resources required by the CQWP, like ItemStyle.xsl which contains the presentation layer of CQWP. Because you have added the WebPart manually you're missing these resources what leads to the error you see. Activating the Publishing Feature should solve your problem.

  • Monday, February 11, 2008 2:03 PManupamamr Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I face the same problem with my site.  The top level site and the site collection has Publishing  Feature activated.  I have a subsite  which is  based on a blog site template. I have publishing activated on the subsite as well. But my CQWP, TOC Web part and Sumamry Links Web part does not work. I get the same error "Unable to ...". I can create a page, but not the one with  Summary Links. I am running MOSS 2007. Any ideas on why this could happen ?

    Thanks
    Anupama
  • Monday, February 11, 2008 2:15 PMWaldek MastykarzMVPUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    What you could try is to reactivate the features just to get sure all required resources are there.