I use WCF service to connect WPF front-end application with ERP back-end database.
I get an WCF service error: "The connection was closed unexpectedly" in my WPF application when trying to load table with many records (about 1000). Everything is going fine on tables with 10 - 20 records.
In my settings of the WCF service I have nothing conserning TimeOut settings. Maybe there are some timeout settings by default. How I can change this?
This is code with settings of my WCF service:
public void Start()
{
BasicHttpBinding binding = new BasicHttpBinding();
binding.Name = "NAVBinding";
binding.HostNameComparisonMode = HostNameComparisonMode.StrongWildcard;
Uri baseAddress = new Uri("http://localhost:8000/nav/customer");
Customer_Service service = new Customer_Service();
serviceHost = new ServiceHost(service, baseAddress);
serviceHost.AddServiceEndpoint(typeof(ICustomer_Service), binding, baseAddress);
OpenMetadataExchange(baseAddress);
service.navEventListner = this;
serviceHost.Open();
}