Datagrid results on page through records format

754
5
Jump to solution
08-21-2014 07:47 AM
MayJeff
Occasional Contributor

I would like to get my datagrid results on page through records like ESRI Sample here:

Query with Feature Layer | ArcGIS API for JavaScript

The sample using Feature Layer and return the object ids for all the records that match.  I am not sure how to change this line of code under queryRecordBy Page function for query.objectIds = pageInfo.results.slide(begin, end) since not using objectIds at all.

Here is JSFiddle:

http://jsfiddle.net/MayJeff00/9nkasc43/

Thank you.

0 Kudos
1 Solution

Accepted Solutions
RiyasDeen
Occasional Contributor III

Hi May,

Here's the modified JSFiddle with paging.

Edit fiddle - JSFiddle

View solution in original post

0 Kudos
5 Replies
KenBuja
MVP Esteemed Contributor

Is there a reason you want to stick with Dojox DataGrids rather than switching over the the new dGrid?

0 Kudos
MayJeff
Occasional Contributor

Sometimes results return more than 300, and would need it to shows 50 records per page.  Or do you have other method to perform this task?  I only find this ESRI Sample can do #records per page..

0 Kudos
KenBuja
MVP Esteemed Contributor

dGrid is the replacement for DataGrid and contains an extension (about halfway down the page) that allows you to set how many records to show at a time. This test page shows the many customizations you can do with the Pagination extension.

RiyasDeen
Occasional Contributor III

Hi May,

Here's the modified JSFiddle with paging.

Edit fiddle - JSFiddle

0 Kudos
MayJeff
Occasional Contributor

Thank you very much.  It works so well.

0 Kudos