Search Paging Web Part

The Search Paging Web Part allows the shopper to iterate through the search results. The shopper can specify a property to sort by and the number of search results per page. The "Sort by" property applies to product search results only. If no results are found, this Web Part is hidden.

The Search Paging Web Part must be connected to a Search Result Web Part. The Search Result Web Part provides the information about total records found for the search request.

This is a user control-based Web Part.

Architecture

The Web Part updates the URL query string parameters and submits the page.

The Web Part always posts back to the current URL.

To connect to a Search Results Web Part, add the Search Results Web Part to the page. Use the edit option on the Search Paging Web Part, select Connections, then select "Get Search Results Count Parameter from" and then select Search Results Web Part.

Properties

The following table lists the mapping of the properties for the Search Paging Web Part.

Property

Map to

CSS Class

CssClass

"Page" text

LinksText

Maximum # of page links after current

MaximumPageLinksAfterCurrent

Maximum # of page links before current

MaximumPageLinksBeforeCurrent

Maximum selectable # of results per page

MaxResultsPerPage

Minimum selectable # of results per page

MinResultsPerPage

"Next" link image URL

NextLinkImageUrl

"Next" link text

NextLinkLabelText

"Previous" link image URL

PrvLinkImageUrl

"Previous" link text

PrvLinkLabelText

"Results per page" label text

ResultsPerPageListText

"Showing records" text

ShowingRecordsText

Display "# results per page" drop-down

ShowResultsPerPage

Display "Sort By" drop-down

ShowSortingList

"Sort by" label text

SortingByListText

Customization

You can customize Search Paging Web Part by using HTML and CSS in the control.

Error Handling

The Search Paging Web Part returns friendly error messages when required fields have not been supplied.

API Dependencies

Catalog API: Use to get the list of product categories.

See Also

Other Resources

Developing with SharePoint Commerce Services

Catalog System Web Parts

Working With the Search Paging Web Part