Hi,
In my controller index method I am calling
return View( viewModel )
where viewModel is of type list and I have to pass Paged list to get pagination links and for that I am using '
return View(viewModel.ToPagedList(pageNumber,pageSize));
and even after that i am using the below
<%: Html.PagedListPager((IPagedList)Model, page => Url.Action("Index",
new { page}),PagedListRenderOptions.PageNumbersOnly)%>
I am able to see only the first page data and when click on second page or other I am not able to load the records
Please explain me the solution for this
What I have tried:
I am passing the viewmodel of type list from controller and when passing to a view some times I am getting the exceptions