Server Software:
SQL Server 2000 (all sp's up to date)
SSRS 2000 (all sp's up to date)
We have an error when a report subscription is sent via email.
Our report definitions reference a key in the web.config file so that we can have a single location to reference our department's name in all reports. Our department name changes frequently as our company is bought and sold and it is difficult to manually update 700+ reports.
In report designer we have a text field with the following value expression:
=System.Configuration.ConfigurationSettings.appSettings("Department").ToString()
Our web.config looks like this:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
....extra settings truncated for brevity...
<appSettings>
<add key="Department" value="Report created by: Corporate Reporting and Analysis" />
</appSettings>
</configuration>
The reports work perfectly in every aspect accept when they are schedules to be emailed. When the email recipient receives the email (not matter what format, mhtl, pdf, etc...) the department string value is replaced with: #Error
Is this a bug with the report schedule and deilvery component? ..or is there a permission problem when accessing: System.Configuration.ConfigurationSettings.appSettings("Department").ToString() ?
Any help would be greatly appreciated.
Thank you
Well, I believe I solved the issue:
The report scheduling service is located in another folder:
C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer\bin\ReportingServicesService.exe
...and its configuration file is called:
ReportingServicesService.exe.config
All we had to do was modify this config file to match our web.config appSettings and "Presto!" it worked.
<configuration>
....extra settings truncated for brevity...
<appSettings>
<add key="Department" value="Report created by: Corporate Reporting and Analysis" />
</appSettings>
</configuration>
Also, remember to restart the "ReportServer" service after updating the ReportingServicesService.exe.config file in order to immediately reset the changes.
No comments:
Post a Comment