Help you master: how to use the code in a WCF configuration changes maxItemsInObjectGraph length limit,
The original code:
ServiceHost host=new ServiceHost (typeof (MainServer), the new Uri (tcpaddress));
Host. AddServiceEndpoint (typeof (IMainServer), tcpBinding, tcpaddress);
ServiceMetadataBehavior behaviors=new ServiceMetadataBehavior ();
Behaviors. HttpGetEnabled=false;
The host. The Description. Behaviors. The Add (Behaviors);
Host. AddServiceEndpoint (typeof (IMetadataExchange), MetadataExchangeBindings. CreateMexTcpBinding (), "tex-mex");
The host. The Open ();