How to maintain chart size when exported to excel? - reporting-services

I have a report that I am developing using SSRS like this:
I created the same report layout using Adventure works to show a detailed explanation of my question since I can't post the exact report that I am working on, for security purposes.
So as you can see, I have the chart above and a table with a drill down below. But I am getting an issue when I am exporting this report into an excel format:
(Report in excel format)
The chart above is distorted by default view of the report's excel version. The chart will come back to it's original size unless I clicked the drilldown of the table (Collapsed) as shown below.
Now my question is, How can I maintain the chart's property particularly the size regardless of whether the drilldown of the table is in collapsed state or not?

Related

Report Preview not displaying data

Need help on this as I'm quite new to using this Telerik Reporting tool.
I've configured my data source to point to the correct database and I've already set the query to be used to display the report. As you can see below, the data is shown in the preview data source result.
However when I preview it in the report designer, it is not showing any report data as seen below.
I need help on what to do in order to display the records in the report. I'm not sure where to check.
For company/Location you need to send ID=126 not name in preview window, same as in data source query.

Don't produce report if there is no data - PDF

I have a report for which there is sometimes no data to output. This report is run along with several other reports and all are then output to PDF. However, this report still produces the header and footer with a blank page even tho there is no data.
I can move the header and footer into the report and have tried to hide those elements with =if(rownumber("PersonalProfile")=0, True, False) in the Hidden property of those elements. It hides everything so now the page is blank, but it will will output a blank PDF. Is there a way to completely suppress the report?
I'm using 2008 and I don't see a Report Visibility property. All the data for the report is inside a single Tablix which is inside a rectangle.
There are 3 datasets: PersonalProfile which contains the meat of the data; BoardNames which just produces the name of the board for the report; BoardMeetings which allows the user to pick a date parameter.
If you are distributing your report using subscriptions and you have Enterprise Edition, then you can look at using Data Driven Subscriptions which will give you control over how and when reports are distributed based on whatever logic you need. Otherwise, there is no way to do what you are asking - as trubs says, Reporting Services must first render the report before it has any knowledge of whether there is any data to display.
You haven't explained how you are "running the reports" (e.g. manually in Report Manager, report subscription, third party app using URL access) - if you do perhaps someone can suggest a workaround.
There is no way to do what you want. ssrs has to produce the report in order to determine there is nothing to display.

SSRS report to be hidden on screen, but data to be shown on export option

I've got a SSRS report with many columns. Showing this report on screen can be tedious to use. I would like to hide this report on screen, but data should be visible when user choses to export via export option on SSRS. On hiding this report, through Tablix properties, it was not visible, but on exporting to CSV/PDF, data was not visible there also. What should be done to show data on export??
Sounds to me like you want to hide report items based on how they're rendered. Use an expression like the following for visibility of your report items:
=Iif(Globals!RenderFormat.Name = "EXCEL", True, False)
Alternatively, if you're using the ReportViewer component currently, I'd suggest replacing it with a regular control in your application framework, and sending a Stream of data with a rendered report (rendered from the SSRS web service).

First page of SSRS report not rendering on initial load

I've created an SSRS report in Report Builder 3 which contains a single-rowed Tablix that holds a sub report which produces a single report per page. The problem is that when I run the report it doesn't render the first page.
Within Report Builder I can never get this first page to display within the executed report and within the web forms ReportViewer control (v10.0.0.0) I can get this first page to appear when I page away and then back to it. Exporting the report also displays all of the correct data.
This issue has only started occurring since I made some slight changes to the layout of the sub report. I've checked the visibility on the tablix, group, row, sub report and all the other settings that I thought might be responsible, but they haven't changed since it was previously working.
I've also tried recreating both the tablix and the entire outer report based on an answer to a similar question and this didn't make a difference.
Any help with this issue would be much appreciated.
I was passing the data for my sub reports through as parameters to prevent the need to call 5000+ single line select statements, and it looks like they need a data set to execute to render correctly on the initial load. Previously, I had mistakenly left a data set within the report, which I must have removed when making the layout changes.
Creating a dummy data set with SELECT ' ' AS Dummy and then using that to populate a text box seemingly fixed the issue. It's not a clean solution but it works.

SSRS 2008 Rendering to Word from URL gives different output to Exporting from Report already rendered on screen

I have a report created in VS2008 on SQL Server 2008 (SP3).
The report comprises of several sub reports nested 3 or 4 levels down in some instances. Document Maps are used extensively so that Word Tables of Contents can be generated further down the line.
Now here's the problem.
If I render to screen either in the development environment or rendered the deployed report from the reporting services server, then everything is OK. If I export the report in any format (tested with Word, PDF & Excel) then the output is as expected.
However, if I create a URL including all the parameters something like
http://MYSERVERNAME/ReportServer/Pages/ReportViewer.aspx?%2fMYPATH%2fMYREPORTNAME&PARAM1=999&PARAM2=999&PARAM3=999&rs:Command=Render&rs:Format=HTML4.0
then paste this into an IE window, the output is incorrect.
Well let me clarify that.
If I render as above using the HTML4.0 rendering extension then the report renders on screen as expected, all the content is shown.
If I render to Word by changing the rs:Format parameter to Word then the report renders but the first page is missing (see note about this content below)
If I render to PDF, the same part of the report is missing.
If I render to Excel, the document map generated on the first workbook sheet shows an entry for the missing section of report but clicking the click gives and 'invalid reference' error and indeed that part of the report is again not rendered.
Note that the 'master' report for want of a better term is made up of 3 subreports, each of these contain other sub reports.
Its the content of the first subreport, that also happens to only every show on the first page (as it is just less than a page long) that is missing.
In Word there is something rendered but it looks like an empty table with a width that is the full width of the page but a heigh of just a few millimetres.
I'm really at a loss as to why the section does not render when it works perfectly if rendered to screen and then exported. I had assumed they would use the same rendering process but I'm not sure.
I'll continue to experiment, maybe add some blank content before the problem section or something and see where I get but I'm puzzled as to why this happens, other reports do not suffer the problem (however I have only tested 3 or 4 or the hundreds that I have written).
I've not used the URL method much in the past but I got to this point as I was writing a c# application to run the same report with varying parameters to produce over 1200 word documents, each of which takes about 2 mins to run. the output was incorrect there so I worked my way back to creating a manual URL and the problem was still apparent, the rest is history!
I finally found the answer.
The subreport that was causing the problems takes parameters that are subsequently passed on to other child subreports. While I was testing these, I had datasets that provided the available values for the parameters (list of countries and their associated ID's for example).
My normal method of working is to remove all datasets that are only used to populate parameters in all subreports as this improves performance (the report does not have to query the database to get a list of countries for example).
However, on this occasion I had removed all the datasets (which in itself was fine) but I had left the datasource in place (visible in the report data pane).
Once I removed this redundant entry, the report rendered as expected.
Now I'm still not sure why it rendered OK to HTML4.0 but it would appear that when rendering to other formats there is some process going on that looks at the datasource perhaps and as there is no data (as there are no datasets) then the report is not rendered. That's a bit of a guess but it's the only thing that makes sense to me at the moment.