Using the URL to sort or filter a list

Archived content. No warranty is made as to technical accuracy. Content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

It's easy to use commands for sorting and filtering lists in your team Web site based on SharePoint™ Team Services from Microsoft®. For example, you can click the name of a column to sort the items, and you can use the Filter command to select columns that contain particular content. However, there may be times when you want to quickly change the sorting or filtering by editing the URL (Web address).

When you sort or filter a list (such as Contacts, Tasks, and so on), parameters for sorting and filtering are appended to the URL for the page that displays the list. The parts of the URL that you would edit appear after the question mark (?) and are separated by ampersands (&). Each part is in the form constant=value, where constant is a term, such as SortField, and value is the information assigned to the constant.

On This Page

Sorting
Filtering

Sorting

For example, in a URL that includes the following:

SortField=Title&SortDir=Desc

The list is sorted as follows:

SortField=Title The list is sorted in alphabetical order by title.

SortDir=Desc The list is displayed in reverse alphabetical order, from the end to the beginning of the alphabet.

If you want to sort by some other field, you would replace Title in the URL with the name of the other field. If you want to sort in ascending order, you would replace Desc in the URL with Asc.

Note: To refresh the page after editing the URL, press ENTER.

Filtering

If a filter is applied to a list, the URL includes information about the filter in the FilterField and FilterValue parameters.

For example, in a URL that includes the following:

FilterField1=Writer&FilterValue1=Chris%20Tobey

The list will display only items where Chris Tobey is the writer. If you want to view items with another writer, you would replace Chris%20Tobey in the URL with the name you want, using %20 for spaces. If you want to view items where Chris Tobey is the value of some other field, you would replace Writer in the URL with the field name you want, such as Editor.

To quickly return to a predefined view of the current list, click the name of a view under Select a View on the page that displays the list.