This is a migrated thread and some comments may be shown as answers.

GridView With Paging not working

3 Answers 67 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Projects Computerra
Top achievements
Rank 1
Projects Computerra asked on 06 Sep 2017, 10:50 AM

Hello, All

<UniControls:UniDataGridView x:Name="grdResult" ShowGroupPanel="False" IsReadOnly="True" RowIndicatorVisibility="Collapsed" AutoGenerateColumns="False"
                              HorizontalAlignment="Stretch" VerticalAlignment="Stretch" CanUserFreezeColumns="False" ScrollViewer.VerticalScrollBarVisibility="Auto" RowLoaded="grdResult_RowLoaded"
                                                Height="550">
                    <grid:RadGridView.Columns>
                        <grid:GridViewDataColumn Header="No" DataMemberBinding="{Binding VisitorNo}" />
                        <grid:GridViewDataColumn Header="Name" DataMemberBinding="{Binding VisitorName}" />
                </UniControls:UniDataGridView>
</Grid>
            <telerik:RadDataPager x:Name="DP" Grid.Row="4"  Grid.ColumnSpan="6" PageSize="2" Source="{Binding}" Height="30" FontSize="12" DisplayMode="FirstLastPreviousNextNumeric" IsTotalItemCountFixed="True" PageIndexChanged="DP_PageIndexChanged" />

Page Index Event
private void DP_PageIndexChanged(object sender, PageIndexChangedEventArgs e)
        {
            if (VisitorScheduleTimeBooth.Count() > 0)
            {
                if (e.NewPageIndex >= 0)
                {
                    intpageindex = e.NewPageIndex;
                    grdResult.ItemsSource = VisitorScheduleTimeBooth.Skip((e.NewPageIndex) * 2).Take(2);
                    grdResult.Visibility = Visibility.Visible;
                }
            }
        }

Paging not working on Telerik File Version 2014.1.225.40 (Telerik.Web.UI.dll) && (Telerik.Web.UI.Skins ) && 2014.1.225.2  for (Telerik.OpenAccess.dll)
As per mention on above screen shot my page loading in Silverlight with grid bind data all are working fine and apply paging with telerik version when I am using DisplayMode="FirstLastPreviousNextNumeric" property all button working but only last button not working
DP_PageIndexChanged Event when I click First, Next, Previous, Numeric button fire on server side and debug my code but not fire on last button click event
Please give me any solution so I resolve my issue

Thanks
Alpesh Patel

 

3 Answers, 1 is accepted

Sort by
0
Dilyan Traykov
Telerik team
answered on 09 Sep 2017, 04:32 PM
Hello Alpesh,

I tested out the scenario you described in the Custom IPagedCollectionView demo from our SDK Samples Browser but the PageIndexChanged event is fired as expected upon clicking the "navigate to page" button at my end. I'm attaching the sample project I've used in the process for your reference.

Could you please have a look at it and let me know how it differs from the setup you have at your end? If possible, please modify the project so that it demonstrates the issue you observe or send over a sample project of your own so that I can further assist you.

Thank you in advance for your cooperation on the matter.

Regards,
Dilyan Traykov
Progress Telerik
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Projects Computerra
Top achievements
Rank 1
answered on 09 Oct 2017, 11:18 AM

Hello Dilyan Traykov

Thanks for your replay

Can you give me one sample of paging with database record so i will try to customize paging with Telerik GridView including in my code

Thanks 

Alpesh Patel

 

 

0
Dilyan Traykov
Telerik team
answered on 12 Oct 2017, 08:28 AM
Hello Alpesh,

I've provided another project using the Northwind database where paging also works as expected. Please note that you may need to modify the connection string inside the App.config file.

Please let me know once you manage to have a look at the project.

Regards,
Dilyan Traykov
Progress Telerik
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
GridView
Asked by
Projects Computerra
Top achievements
Rank 1
Answers by
Dilyan Traykov
Telerik team
Projects Computerra
Top achievements
Rank 1
Share this question
or