Set a table's visibility to false when it has no rows (in reporting services)

Sophia picture Sophia · Feb 5, 2009 · Viewed 91.7k times · Source

Is there a way to set a table's visibility to false, if the table has no rows?

I want to hide a table in Reporting Services when it has no rows.

Setting NoRows to ="" isn't sufficient in this case as space is still left for the table, and some of the table's formatting is still visible.

I'm using Microsoft Visual Studio / SQL Reporting Services 2005

Answer

Matt Hamilton picture Matt Hamilton · Feb 5, 2009

Try setting the table's "Visibility.Hidden" property to this expression:

=CountRows() = 0