It may not be possible to set the trust level for only one page, but you can split the page with the ReportViewer
control into a new web application and, therefore, into a new application domain. Therefore, changes to web.config only affect the report view page.
There are also some other advantages to this workaround, such as:
- The ability to scale a reporting website in different ways, as it typically consumes a lot of resources.
- the ability to disable session state for the main website for performance reasons and keep it enabled only in reports, because ReportViewer requires session state
source share