Greetings from Syncfusion support.
We don’t have direct support to render the Pager control at the top of the Grid. but we have achieve your requirement by calling a JavaScript function using JSInterop in DataBound event of Grid to insert the Pager Control on top of grid using JavaScript function. Refer the below code example.
<SfGrid @ref="Grid" DataSource="@Orders" AllowGrouping="true" Toolbar=@Tool AllowPaging="true">
<GridPageSettings PageSizes="true"></GridPageSettings>
<GridEvents DataBound="DataBound" TValue="Order"></GridEvents>
. . . . . . . .
</SfGrid>
@code{
SfGrid<Order> Grid { get; set; }
public List<Order> Orders { get; set; }
public async Task DataBound()
{
await Runtime.InvokeVoidAsync("RenderPagerTop", Grid.ID, Grid.AllowGrouping, Grid.Toolbar);
}
. .. .. . .. . .
function RenderPagerTop(id,enabledGrouping, toolbar) { var grid = document.getElementById(id); var pager = document.getElementsByClassName('e-gridpager'); var topElement; if (enabledGrouping || toolbar) { topElement = enabledGrouping ? document.getElementsByClassName('e-groupdroparea') : document.getElementsByClassName('e-toolbar'); } else { topElement = document.getElementsByClassName('e-gridheader'); } grid.insertBefore(pager[0], topElement[0]);}
|
Refer the below screenshot for your reference
Kindly download the sample from below
Refer our UG documentation for your reference
Please get back to us if you have further queries.
Regards,
Renjith Singh Rajendran