Data Layout - Do you avoid using a single chart when you need it to be scaled?

Last updated by Jeoffrey Fischer [SSW] about 1 month ago.See history

Figure: Bad example - Just a chart - poor scaling for only 1 record

Figure: Bad example - Just a chart - poorly scaling when many records

The reason for this problem is that the 'size' property of the chart control doesn't support expressions like 'Count(Rows) or queried values like 'Fields!RowCount.Value', so the chart control cannot adjust its size according to the data.

The solution for this problem is to use an embedded chart within the table - this will create a dynamic chart list similar to the list shown below.

ChartProperties size
Figure: Size property of the chart control

Figure: Good example - A table with chart

To do this, you need to create a table in your report and add a chart into each of the rows.

Figure: Embedded chart in a table will generate dynamic chart list

Note: When rendering a report to your browser or an email, Reporting Services generates a separate image for every single image in the report, even if they are identical. When you are using graphs, images or charts in your report, this can cause a large number of images to be generated. Always include a red warning at the top of any emailed reports so that users do not try and forward or reply to them. Use a warning like this:

Warning: Do not reply to or forward this report in an email - Outlook may slow down or even hang.

We open source. Powered by GitHub