serializer.Serialize Error during serialization or deserialization using the JSON JavaScriptSerializer. The length of the string exceeds the value set on the maxJsonLength property code example

Example: Error during serialization or deserialization using the JSON JavaScriptSerializer. The length of the string exceeds the value set on the maxJsonLength property.

<configuration>  
   <system.web.extensions>
       <scripting>
           <webServices>
               <!-- Update this value to change the value to 
                    a larger value that can accommodate your JSON 
                    strings -->
               <jsonSerialization maxJsonLength="86753090" />
           </webServices>
       </scripting>
   </system.web.extensions>
</configuration>