SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is it possible to select which views of a document library that should be available in a web part displaying the document library? This seems to partially solve the problem:

However, I want end users to be able to select which views to be available in the web part themselves.

share|improve this question

migrated from Apr 19 '12 at 12:39

This question came from our site for professional and enthusiast programmers.

There is a drop down in the article that you've provide - that is filled with hard coded view names - user selects a view and it's shown in the webpart. So I suppose the webpart fulfill your requirement.

share|improve this answer
Thank you for your answer. However, the code provided above does not allow end users to choose available views for the web part themselves. I chose to inherit System.Web.UI.WebControls.WebParts.EditorPart to enable that. – Martinfy May 8 '12 at 12:30
I suppose it should provide, not sure about your implementation. There is a DropDownList with ID="DropDownViews", there you should hard code (in advanced version you can get them) view names, on page_load selected view is received from the dropdown. – Yuri Leontyev May 8 '12 at 17:58

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.