Minimize
08
 

In the last tutorial in this series of Reporting Services tutorials we added conditional formatting to the report. Now that we’ve created our first report and have added a bit of flare to it, let’s go ahead and make it even cleaner. In this very quick demonstration, we’ll go ahead and change the visibility of rows or columns based on given conditions.


Other articles in this series (in order):



In our example, we’re going to continue with our SQL Server job monitor report. This tutorial will filter out jobs that are not enabled. In our scenario we don’t care about jobs that are disabled and we’re assuming they were disabled with good reason. To do this, follow these steps:



  1. Select one of the fields in the report in the Visual Studio report design interface. Once you select the field, you’ll see a grid surrounding the row. Left-click on the grey column to the left of the data as shown in the below figure. By left-clicking on this row, you can now set the properties for the entire row and not a single column in the table.
  2. The property you want to set in the right-pane is the Hidden property under the Visibility group. If you don’t see the Properties window on the right as seen in the above screenshot, select Properties Window under View. The default visibility property is True. To change this to our dynamic property, click the drop-down box and select .
  3. You should now be in the Edit Expression dialog box as shown in the below screenshot. In the Expression box to the right you can type the following syntax to change the visibility (make sure you remove what was there before):

    =iif (Fields!enabled.Value = 0 OR Fields!enabled.Value IS Nothing, True, False)

    Essentially, this will change the Hidden property to True if the value of the enabled column is 0 or NULL. Otherwise, the Hidden property will be set to false.

  4. Click OK and preview the report. If you have any jobs that are disabled, they will not show in the report any more. 

If you want to change the properties of an individual group, column or header you can follow the same logic. Even graphics can be hidden or shown with this technique. In those cases you would just select the individual object and go to the Hidden property again. That’s all there is to it! Sorry, I couldn’t stretch it out further. Currently, I’m taking this series from common newsgroup posts. If you have any areas that you’d like to see documented, please click on Opinion below to post a message to me.


Comments

There are currently no comments, be the first to post one.

Post Comment

Only registered users may post comments.

LatestArticles Minimize
Changing Granularity of Leaf Level Calculations in SSAS Tabular by Jason Thomas

Finding Nearest Stores using SSRS Map Reports by Jason Thomas

Heat Maps for SSRS using Map Control by Jason Thomas

Parameters for Analysis Services Reporting: Introduction, Pt. 3 by William Pearson
BI Architect Bill Pearson continues an extended examination of parameterization within Analysis Services reports. In this, Part 3 of the article, we continue to get hands-on practice cr...

Parameters for Analysis Services Reporting: Introduction, Pt. 2 by William Pearson
BI Architect Bill Pearson continues an extended examination of parameterization within Analysis Services reports. In this, Part 2 of the article, we continue to get hands-on practice cr...

Using Annotation Tables in SSAS to Show Last Processed Time and Latest Data Updates as a Measure in a Cube by John Hall

Using Color in SSRS Charts by Melissa Coates
Effective data presentation techniques help users  interpret information quickly and reliably.  Layout, formatting, sizing, labeling, and other report elements may all be used to facilitate ...

Is TOAD faster than BIDS Query Builder? by John Hall

SSRS: Unexplained Warning “This field is missing from the returned result set from the data source” And Checking a Field for Null Exception by John Hall
If you ever see the warning message “This field is missing from the returned result set form the data source” and get unexplained #Errors in columns on your report it may be from SSAS not returning a ...

Beyond Excel pivot tables: Leveraging cube formulas with MDX by Javier Guillen
PowerPivot and DAX are a powerful technologies, but there is still a good amount of work that can be done with traditional cube functions. In its current version, PowerPivot lacks the concept of ...


Advertisement Minimize

Advertisement Minimize

Copyright 2004-2012 MSBICentral.com Terms Of Use Privacy Statement