Screencast – Display a Document Library List in Multiple Sites
Many times you’ll find the need to display the same document list in multiple places on your site, or even on other sites within the same site collection. That’s pretty simple to do using the Content Query Web Part. To see a screencast demo go to the Video On-Demand page.
Or else you can follow these steps:
Move to the page where you want the list to be displayed
- Site Actions -> Edit Page
- Click ‘Add a Web Part’ in the area you want the list to be displayed
- Scroll down to the Default section and choose Content Query Web Part
- Click Add button at bottom of window
- Note: A default output will be showing in the web part… ignore it
- Menu dropdown: edit -> Modify Shared Web Part
- Expand the Query tab in the tool box
- Choose Show items from the following list radio button
- Browse to your selected list
- Click OK after selecting list
- IMPORTANT: In the ‘Show items from this list type’, choose Document
Library - Click the Apply button to verify results
- Tweak as necessary
Knowing how to use the Content Query Web Part is one of the best tools available in your search for ‘One Version of the Truth’ when building content for multiple locations and sites. I added a videocast to the Video On-Demand library. Please take a look and give me some feedback as to how you will use this technique.
Thank you for this article. It was exactly what I was looking for.
One question, though. Is there a way to only show the contents of a particular folder. In my case, I’m looking to add only the contents of the root folder of a document library, but I’m seeing all of the documents within subfolders as well.
Thanks in advance.
Alan – A quick hack would be to put a special field/column in the root library that doesn’t appear in the subfolders, set a default value so it will always appear when a file is uploaded or cteated, then filter by that special column… only root folders will appear.
Regards,
Mark
Hi,
I’m fairly new to Sharepoint, and I cant find the Content Query Web Part. I run a swedish version of Sharepoint and found a “QueryByContentWebPart” in the gallery, but It says that the webpart doesn’t work when i try using it. “Contact the administrator if this problem…”, but I’m the administrator in this case. :)
Any ideas?
Thanks for the VOD tutorial. Do you know the name of the webpart file (*.dwp, *.webpart). I can’t find it under default. Somehow it is not loaded , possible? I really need to use it. Thanks.
Clee – You need to have the Publishing features turned on in order to have access to the CQWP.
Regards,
Mark
Is Publishing features only avaliable with MOSS or is it avaliable for WSS and if so how do I find it, because I can’t find it anywhere.
Thanks in advance for any help you can give.
Good stuff… Any suggestions on whether you could use this functionality across site collections, especially from My site lists?
For instance if I wanted to display a user’s My Links list onto a page?
Gavin – That’s the real problem, isn’t it? The limitation of only being able to access data within a single site collection is a deal breaker for any implementation of size.
The current answer is to use third party web parts such as that made by Quest or CorasWorks. Personally, I am waiting for Bob Mixon to finish the one he is working on.
Do some research on third party web parts for cross site collection access and see what else you can come up with. I’d like to hear what you come up with.
Regards,
Mark
Yeah Mark,
And also the fact that if you’re looking to deploy this as functionality for all users (it’s really a custom list that I want to add into users My Sites when they get created, like Steve Peschka’s article here: http://blogs.msdn.com/sharepoint/archive/2007/03/22/customizing-moss-2007-my-sites-within-the-enterprise.aspx), then the location of the list is going to need to be built up dynamically I guess!
Am going to go a-looking now!
Hi Mark,
How to parameterize the Content Query Webpart.
I am new in the Sharepoint world. I got a project which has to collect the customer information in one site. I have mad a Webpart to list the customer name and a Webpart that should show some of the document for the chosen customer and when you click on one of the customer name in the list the Webpart with the document should be updated and has to show the document for this customer. If I use the Content Query Webpart I don’t know how to give the parameter. I can’t se the Content Query Webpart takes parameter. So can hardcode the Content Query but it well not be a dynamically solutions of the problem.
Will you please come with a suggestion
Hi Mark,
I wanted to show some announcements from a news site. The CQTP only shows me the headers of those announcements but nog the body text. Is there a way to get this to work?
Kind regards.
Good post. However, what is the difference between this and defining a special view on a document library, and then using the document library web part for that library with the special view selected?
Brad – The document library web part is only available in the site in which the library resides. — Mark
Like Brad, I’m not too clear about the difference between using CQWB vs. ‘list view’. if the only difference is where the library resides, then don’t ‘list views’ become redundant? isn’t it easier just to use CQWB?
Hi.
I’ve just tried out this feature, and i works. My problem though, is that I want to show only parts of a library using the CQWP (’cause I can’t find any other way…).
I’ve got a doc. library in my site grouped by document category (not a content type). I only want to see one category in the CQWP in the other site (same site collection).
– the list appears to be a link-list
– the list can’t be filtered; then it only shows message that it didn’t return any errors, if you want to configure a query etc…
Is it possible to show the list as a “in-site” list – including the toolbar?
Thanx for any comments
J
Note: the problem isn’t the layout – it’s the functionality thats missing…