Customizing a List View Web Part can be confusing if you don’t know what’s going on. When you open the Web Part Tool Pane (by clicking the dropdown on the Web Part and choosing Edit Web Part), you have the option to select a pre-existing view or to edit the current view:
When you select a view, the message box that pops up does a good job of warning you that all of your changes are going to be wiped out, but it doesn’t really explain what is going on:
Behind the scenes, when you add a List View Web Part to the page, a hidden view is created just for that Web Part. When you select a view from the dropdown, it is really just making a copy of that selected view and using that as the hidden view for the Web Part. Armed with that knowledge, you should be able to better understand these common scenarios:
– You’ve added a List View Web Part, edited it, and selected a view from the dropdown. You save your changes, but when you go back in to edit the Web Part, it shows <Current view> in the dropdown instead of the view you selected.
– You’ve added a List View Web Part, edited it, and selected a view from the dropdown. You save your changes, but then go to the List Settings and edit the same view you had selected from the dropdown. You change the filters on the view and go back to your Web Part, but your new filters aren’t applied!
– You click the Edit the current view hyperlink and the edit view page appears, but you do not have the option to name the view or change the address:
Now that you better understand how these hidden views work, you can ensure that your List View Web Parts always display the view configuration you expect.
Raymond Mitchell is a consultant with Rackspace Hosting, co-author of “SharePoint 2010 Six-in-One,” and a frequent speaker at SharePoint community events. His blog can be found at www.iwkid.com.