Beispiel #1
0
        public static bool TryCreate(ReportServerInfo reportServer, out IWsWrapper result, out Exception exception)
        {
            RS.ReportingService proxy = new RS.ReportingService
            {
                Url         = reportServer.GetServiceUrl(SERVICE_NAME),
                Timeout     = reportServer.Timeout ?? -1,
                Credentials = reportServer.CreateCredentials(SERVICE_NAME)
            };

            try
            {
                proxy.ListSecureMethods();
                result    = new WsWrapper2003(proxy);
                exception = null;
                return(true);
            }
            catch (Exception e)
            {
                proxy.Dispose();
                result    = null;
                exception = e;
                return(false);
            }
        }
Beispiel #2
0
 // Methods
 /// <summary>
 /// Initializes a new instance of the <see cref="WsWrapper2003"/> class.
 /// </summary>
 /// <param name="proxy">The report server.</param>
 private WsWrapper2003(RS.ReportingService proxy)
 {
     _proxy = proxy;
 }