0

我的应用程序与 WCF 服务 (.NET 4.5) 连接。我使用 slsvcutil (silverligth 5) 构建代理并且工作正常。但我有超时问题。我收到一个超过 1 分钟的错误。这是我的代码:

                    BasicHttpBinding bindin = new BasicHttpBinding();
                    bindin.MaxReceivedMessageSize = 267386880;

                    var timeout = new TimeSpan(0, 10, 0);
                    bindin.SendTimeout = timeout;
                    bindin.OpenTimeout = timeout;
                    bindin.ReceiveTimeout = timeout;

                    wcf = new ServicioInasaClient(bindin, new EndpointAddress(editHost.Text));

谢谢

4

1 回答 1

0

我解决了它:

 wcf.InnerChannel.OperationTimeout = timeout;
于 2013-04-24T14:26:57.330 回答