Esempio n. 1
0
        public static SSRSVersion GetSqlServerVersion(ReportingService2005 reportServerConnection)
        {
            if (reportServerConnection == null)
            {
                throw new ArgumentNullException("reportServerConnection");
            }

            reportServerConnection.ListSecureMethods();

            return(GetSqlServerVersion(reportServerConnection.ServerInfoHeaderValue.ReportServerVersion));
        }
Esempio n. 2
0
        public static bool TryCreate(ReportServerInfo reportServer, out IWSWrapper result, out Exception exception)
        {
            ReportingService2005 proxy = new ReportingService2005()
            {
                Url         = reportServer.GetServiceUrl(SERVICE_NAME),
                Timeout     = reportServer.Timeout ?? -1,
                Credentials = reportServer.CreateCredentials(SERVICE_NAME)
            };

            try
            {
                proxy.ListSecureMethods();
                result    = new WSWrapper2005(proxy);
                exception = null;
                return(true);
            }
            catch (Exception e)
            {
                proxy.Dispose();
                result    = null;
                exception = e;
                return(false);
            }
        }