2 回答
TA贡献1853条经验 获得超6个赞
尝试这样的事情,让我知道......
NTEGRAWSSOAPClient _wsProtheus = null; // NTEGRAWSSOAPClient is a SOAP client class generated by vs2017 on register webservice
var endpointConfiguration = NTEGRAWSSOAPClient.EndpointConfiguration.INTEGRAWSSOAP; //INTEGRAWSSOAP is a ConfigurationName of service
_wsProtheus = new NTEGRAWSSOAPClient(endpointConfiguration,new EndpointAddress("http://new address?wsdl", new SpnEndpointIdentity("your identi")));
BasicHttpBinding bind = (BasicHttpBinding)_wsProtheus.Endpoint.Binding;
bind.CloseTimeout = TimeSpan.Parse("02:00:00");
bind.OpenTimeout = TimeSpan.Parse("02:00:00");
bind.ReceiveTimeout = TimeSpan.Parse("02:00:00");
bind.SendTimeout = TimeSpan.Parse("02:00:00");
bind.MaxBufferPoolSize = Int32.MaxValue;
bind.MaxBufferSize = Int32.MaxValue;
bind.MaxReceivedMessageSize = Int32.MaxValue;
bind.ReaderQuotas.MaxDepth = 32;
bind.ReaderQuotas.MaxStringContentLength = Int32.MaxValue;
bind.ReaderQuotas.MaxArrayLength = Int32.MaxValue;
bind.ReaderQuotas.MaxBytesPerRead = Int32.MaxValue;
bind.ReaderQuotas.MaxNameTableCharCount = Int32.MaxValue;
bind.Security.Mode = BasicHttpSecurityMode.None;
- 2 回答
- 0 关注
- 131 浏览
添加回答
举报