I had some difficulties to retrieve the Total Row Count from a SqlDataSource. I used the results from the SELECT statement in the SqlDataSource to create a ListView, but got stuck to produce some code that would let me easily get the Total Row Count. I won't show all the different code i used, but show you the easy solution.