Load SharePoint integrated reports
To render SharePoint integrated SSRS reports in the Bold Reports® WPF Report Viewer, set the ReportPath, ReportServerUrl and ReportServerFormsCredential properties as in the following code snippet:
this.reportViewer.ReportPath = "http://<servername>/reportserver$instanceName/SSRSSamples/Territory Sales.rdl";
this.reportViewer.ReportServerUrl = "http://<servername>/reportserver$instanceName";
this.reportViewer.ReportServerFormsCredential = new BoldReports.Windows.ReportServerFormsCredential("ssrs", "RDLReport1");
this.reportViewer.RefreshReport();How do I set data source credentials for shared data sources?
To connect shared data sources with the database, add their credentials to the DataSourceCredentials property of the Report Viewer.
this.reportViewer.ReportLoaded += (sen, arg) =>
{
List<BoldReports.Windows.DataSourceCredentials> dataSourceCrdentials = new List<BoldReports.Windows.DataSourceCredentials>();
foreach (var dataSource in this.reportViewer.GetDataSources())
{
BoldReports.Windows.DataSourceCredentials crdentials = new BoldReports.Windows.DataSourceCredentials();
crdentials.Name = dataSource.Name;
crdentials.UserId = "ssrs1";
crdentials.Password = "RDLReport1";
dataSourceCrdentials.Add(crdentials);
}
this.reportViewer.SetDataSourceCredentials(dataSourceCrdentials);
};
this.reportViewer.ReportPath = "http://<servername>/reportserver$instanceName/SSRSSamples/Territory Sales.rdl";
this.reportViewer.ReportServerUrl = "http://<servername>/reportserver$instanceName";
this.reportViewer.ReportServerFormsCredential = new BoldReports.Windows.ReportServerFormsCredential("ssrs", "RDLReport1");
this.reportViewer.RefreshReport();Data source credentials must be added for shared data sources that do not have credentials in the connection strings.