Please review the site disclaimer before downloading or using content found on this site
The formatter threw an exception while trying to deserialize the message: There was an error while trying to deserialize parameter http://v100k.Web.Services:GetListOfOrdersResult. The InnerException message was 'Maximum number of items that can be serialized or deserialized in an object graph is '65536'. Change the object graph or increase the MaxItemsInObjectGraph quota. '. Please see InnerException for more details.
I’m not sure that I’ve quite got the handle on the above issue, but I did get it fixed, and I’m going to put as much here as I can in case I run into it again.
The key was to add an EndpointBehavior to the app.config file and then to reference it in the Client Endpoint. Find both occurrences of ‘LargeObjectGraphBehavior in the code below:
Next, in code, I had to change this:
To this:
Apparently using the constructor wiped out the additional behavior.
I’m going include the entire method below in case I need it later… but the essentials are above