tags:

views:

112

answers:

2

Hi,

I'm using the Contrib Grid for ASP.NET MVC and I was wondering if there is a way to get the number of rows to be output from the grid renderer? I'm trying to not add stuff from the renderer if there are no rows that are going to be shown.

Thanks

A: 

The number of rows is the same as the number of records in your underlying data source.

Robert Harvey
and how do you get to that data from the renderer?
Bruce227
What are you using for a data source?
Robert Harvey
A: 

I found out it is baisically using the DataSource which is defined in the grid renderer and getting the count. So DataSource.Count().

Bruce227