Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
20
problem while getting number of rows of the grid in javascript
posted

Hi

my script method is somewhat like this

1. function rowcount()

2. {  

3. var grid = ig.grid.getGrid("gridID");

4. var r = grid.Rows.length;

5. }

 

when i try to run this script it shows an error message as

is null or not an object at the line  number 4.

Is there any other way through which i can get the count of rows in my grid.

Parents
No Data
Reply
  • 1579
    Verified Answer
    posted

    Hi, karthik422!

    I'm affraid currently our WebGrid cannot collaborate with JavaScript. This will be fixed in one of our next releases. Now you can get the rows' count by calling the grid.getRows().size() method in the backing bean, where grid is a GridView property.

    Regards!

Children
No Data