1
votes

I have three pages in a SharePoint site lets call them ViewA.aspx, ViewB.aspx, and ViewC.aspx.

These three views have List View Webpart on then and all of them get Data from the same list. Lets call it DetailList

I have designed all the three pages so that they only take few Column from DetailList. In the list view webpart.

In this List (DetailList) I have a Dropdown (choice) column lets say with option A, B and C.

When someone comes and enter data in the list (+Add New Item). How do I make it so that if the person pick option A from the dropdown column, the added item can be seem on ViewA.aspx but not on ViewB.aspx and ViewC.aspx, and similar process with B and C.

The only resource I have is SharePoint Designer 2010.

2

2 Answers

0
votes

Adding a choice field with a value for each view would allow the views to filter on that value. This is the least amount of work.

If you want to improve the usability of the solution...

Editing the Newform.aspx to add a content editor webpart would allow you to add a jQuery function to set the appropriate field based on a querystring (i.e. ?DefaultFieldXTo=ViewB)

The last step is to find a way to make sure the Add New Item link has the appropriate querystring added (maybe a job for jQuery content editor webpart again)

Alternatively, it may be possible to craft filters on the views themselves to show different items based on already caputured fields.

0
votes

I figure this out.

I used Filter for the List View. It works as desired.