tags:

views:

1815

answers:

3

I want to place a Webpart on a page that holds a subfolder of the Document Library in SharePoint, but somehow, the only thing I get is the root folder of the document library.

Is there a Webpart that fills this need?

+1  A: 

By default I don't think that is possible.

The list web part that would show the Shared Documents understands how to render the library, but doesn't understand how to filter to only show the contents of one subfolder.

It would be nice to create a Filter Web Part and to provide that filter to the List web part so that it filters according to the sub folder defined within the fileref field of the document library. However the filters it appears to be able to consume are Type, Modified and Modified By. So you could filter it to just the documents you touched, but not the ones in a given location.

End result: Roll your own web part.

+1  A: 

I think this is a good example of why using folders is worth trying to avoid;

Specifically filtering on meta-data built in, whereas what you are trying to achieve has a limited amount of solutions.. (the dataview webpart comes to mind as a possible solution)

easiest is to add some metadata and filter with the default "Shared Documents" webpart i think (e.g. boolean to decide if it should show on front page)

here's an older blog post that covers the reasons to avoid folders detail

A: 

The reason is that the folder selected by the webpart is not controlled by the webpart itself, but by a querystring parameter.

e.g.

"?RootFolder=%2fDocuments%2fMyFolder1&FolderCTID="

So folders are not "real" folders as such, despite the "lie" that is the webdav interface e.g. \\sharepointsite\documents

There should be a way of including the desired RootFolder parameter, like a linking to the page with the querystring included (far from ideal).

I do not know of any webparts that do this.

Nat