ActiveReports 9 Server User Guide > How To > Use the Designer Web Control |
The Web controls need to be directed to the server used for ActiveReports 9 Server in order to function. In your production application, specify the user name and password based on the current user and store information in the current session to persist these values.
If you need to add the control to your toolbox, drop down these steps.
You can specify the security token and ActiveReports 9 Server host using code in a Global Application Class.
To provide a handler for the event
C# code. Paste INSIDE the Application_Start event. |
Copy Code
|
---|---|
ReportServiceProxy.ResolveRemoteEndpoint += ResolveRemoteEndpoint; |
To import the Servicing namespace
ASP.NET code. Paste in the Global.asax file on the line BELOW the Application Language line. |
Copy Code
|
---|---|
<%@ Import Namespace="ActiveReports.Server.ReportControls.Servicing" %> |
To create the ResolveRemoteEndpoint event
C# code. Paste in the Global.asax file AFTER the Application_Start event. |
Copy Code
|
---|---|
static void ResolveRemoteEndpoint(RemoteEndpoint remoteEndpoint) { remoteEndpoint.Address = "http://localhost:8080"; remoteEndpoint.SecurityToken = "MySecurityToken"; } |
You can also specify the user name, password, and ActiveReports 9 Server host in your web application's web.config file.
To provide a handler for the event
C# code. Paste BETWEEN the <configSections> and </configSections> tags. |
Copy Code
|
---|---|
<sectionGroup name="activereports.server"> <section name="reportServiceProxy" type="ActiveReports.Server.ReportControls.Configuration.ActiveReportsServerSection, ActiveReports.Server.ReportControls, Version=x.x.xxxx.x, Culture=neutral, PublicKeyToken=d557f2f30a260da2" allowDefinition="Everywhere" /> </sectionGroup> |
To import the Servicing namespace
ASP.NET code. Paste in the web.config file BELOW the </configSections> tag. |
Copy Code
|
---|---|
<activereports.server> <reportServiceProxy remoteReportServicePath="http://localhost:8080/" username="Admin" password="1" /> </activereports.server> |