Article ID: 120023, created on Feb 7, 2014, last review on Dec 5, 2014

  • Applies to:
  • Operations Automation

Symptoms

Office 365 tasks fail and the "Operation is not valid due to the current state of the object" error message appears in the task logs.

Cause

On the IIS web server running the Office 365 Gateway Application the maximum number of form keys, files, and JSON members is limited to 1000 in an HTTP request. See http://support.microsoft.com/kb/2661403 for details.

Resolution

Increase the corresponding limits:

1. Log on to the IIS web server running the Office 365 Gateway Application.
2. Open the settings.config file of the Office 365 Gateway Application in a text editor.
3. Add the following entries to the file after the <appSettings> entry:
    <add key="aspnet:MaxHttpCollectionKeys" value="20000" />
    <add key="aspnet:MaxJsonDeserializerMembers" value="20000" />
4. Save the file.
5. Restart IIS.

5356b422f65bdad1c3e9edca5d74a1ae caea8340e2d186a540518d08602aa065 e12cea1d47a3125d335d68e6d4e15e07

Email subscription for changes to this article
Save as PDF