ASPxClientDataView.SetPageSize(pageSize) Method
Sets the size of a single ASPxDataView‘s page.
Declaration
SetPageSize(
pageSize: number
): void
Parameters
Name | Type | Description |
---|---|---|
pageSize | number | The page size. |
Remarks
Depending on the selected layout mode, the SetPageSize method sets the page size in different formats.
- For the Table layout, the passed value corresponds to the server-side DataViewTableLayoutSettings.RowsPerPage property and indicates the number of rows displayed on one page.
- For the Flow layout, the passed value is the number of data records displayed on a single page. It corresponds to the server-side DataViewDivBasedLayoutSettings.ItemsPerPage property.
To get the page size on the client side, use the ASPxClientDataView.GetPageSize method.
Note that the SetPageSize method has affect only if the page size item element is visible and it contains an item with the page size passed to this method.
<dx:ASPxDataView ID="ASPxDataView1" runat="server" ClientInstanceName="dataView">
<PagerSettings Visible="true">
<PageSizeItemSettings Items="2,3,5,10" Visible="true">
</PageSizeItemSettings>
</PagerSettings>
...
See Also