Using TeamCity to Deploy SSRS 2008 R2 Reports

We strive to integrate our SSRS 2008 R2 projects into our automatic build process. Three times a week, TeamCity currently creates and deploys our C # database. We would like to add to this the draft SSRS reports. RDL files are currently in the Subversion version control repository.

+8
reporting-services teamcity
source share
1 answer

For this purpose, you can use the report server web service . This method has a CreateItem that loads the report into the report service.

To create a C # project that loads rdl files, you need to create a proxy class for your ReportService2010.asmx endpoint, and then use it like this

ReportingService2010 reportingService = new ReportingService2010(); reportingService.Url = url + "/ReportService2010.asmx"; reportingService.Credentials = new System.Net.NetworkCredential(username, password, domain); Microsoft.SqlServer.ReportingServices2010.Warning[] warnings = null; using (FileStream reportStream = new FileStream("c:\\report.rdl", FileMode.Open, FileAccess.Read)) { using (MemoryStream ms = new MemoryStream()) { reportStream.CopyTo(ms); CatalogItem report = reportingService.CreateCatalogItem( "Report", "Report1", "/", true, ms.ToArray(), null, out warnings); } } 
+4
source share

All Articles