ParamQuery grid support forum

General Category => Help for ParamQuery Pro => Topic started by: Robert on April 18, 2014, 08:16:40 am

Title: How do I get totalRecords count?
Post by: Robert on April 18, 2014, 08:16:40 am
Hi,

This may be a silly question but I can't seem to find an example where someone has pulled the totalRecords count.

Is it possible to get the totalRecords integer in such a way similar to this:

var recID = $grid.pqGrid("getRecId", { rowIndx: rowIndx });

Thanks in advance!
Title: Re: How do I get totalRecords count?
Post by: paramvir on April 18, 2014, 10:55:52 am
That makes sense.

Total number of records is the length of dataModel.data.

var totalRecords = $grid.pqGrid('option', 'dataModel.data' ).length;

It can also be obtained from pageModel.

var totalRecords = $grid.pqGrid('option', 'pageModel.totalRecords');
Title: Re: How do I get totalRecords count?
Post by: Robert on April 18, 2014, 03:56:15 pm
excellent. thank you!