Imports SSRS_TO_PDF.ReportingServiceWebReference Imports System.IO Imports System.Web.Services.Protocols Module Module1 Sub Main() Dim RS As New ReportingServiceWebReference.ReportingService2010 Dim ex As New ReportingService2010 RS.Credentials = System.Net.CredentialCache.DefaultCredentials 'RS.Credentials = System.Net.CredentialCache.DefaultCredentials Dim reportName As String = "http://192.168.108.23/Reports/Pages/Report.aspx?ItemPath=%2fGROW%2fUser_Tb_Server_Check" Dim reportDefinition As Byte() = Nothing Dim doc As New System.Xml.XmlDocument Try reportDefinition = RS.GetItemDefinition(reportName) Dim stream As New MemoryStream(reportDefinition) 'write to pdf file Dim file As New FileStream("C:\Temp\TestReport3.PDF", FileMode.Create, FileAccess.Write) stream.WriteTo(file) file.Close() stream.Close() Catch e As SoapException Console.WriteLine(e.Detail.InnerXml.ToString()) MsgBox(e.ToString) Catch e As IOException Console.WriteLine(e.Message) End Try End Sub End Module
<pre>...</pre>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)