The RSViewerPage.aspx is a Out the boxed application page in the _Layouts folder.
Application pages, which are also known as "_layouts" pages, are
stored in a site's Microsoft Internet Information Services (IIS)
virtual directory and support application implementations. Application pages are shared across all sites on the server, whereas a site page is specific to one site.
Change these files is not recommended, because when microsoft decides to change this page in a future release all your changes are gone.
What you can do is create your own application page.
Copy the RSViewerPage.aspx and rename it, for example RSViewerPageWebAppA.aspx than add your own branding.
To override an applicationpage its also possible to HttpModule
An HTTP module is an assembly that is called on every request made to
your application. HTTP modules are called as part of the ASP.NET
request pipeline and have access to life cycle events throughout the
request. HTTP modules therefore give you the opportunity to examine
incoming and outgoing requests and take action based on the request.
First you create a new class that implements the IHttpModule interface
public class RSViewerPageModule : IHttpModule
Add an event to the init function
public void Init(HttpApplication context)
context.PreSendRequestHeaders += this.ChangeApplicationPage;
Create the method like
private void ChangeApplicationPage(object sender, EventArgs e)
System.Web.HttpApplication httpApplication = (System.Web.HttpApplication)sender;
string path = httpApplication.Request.Path;
After you created the class you must register the module in the web.config
This can be done manually, but in a feature its better
<add name="RSViewerPageModule" type="<here your type>" />