This is a migrated thread and some comments may be shown as answers.

Error during serialization or deserialization using the JSON JavaScriptSerializer.

1 Answer 289 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Manish
Top achievements
Rank 1
Manish asked on 05 Jan 2016, 04:08 AM

Hi,

I am using Grid - Virtualization. But when I try to load huge data getting an error "Error during serialization or deserialization using the JSON JavaScriptSerializer. The length of the string exceeds the value set on the maxJsonLength property." where as also I am using  "OnNeedDataSource"

As per my requirement I need to create Grid columns at run time as don't know how many columns and rows we be there as query output.

I have also used below code in my config file but don't get any success

 <system.web.extensions>
    <scripting>
      <webServices>
        <jsonSerialization maxJsonLength="2147483647" />
      </webServices>
    </scripting>
  </system.web.extensions>

 

Can any body help me out in this.

Thanks

1 Answer, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 05 Jan 2016, 08:26 AM
Hello,

The reason for the serialization error is that too much data is serialized at once. Therefore I suggest you try lowering the InitiallyCachedItemsCount on your end (set lower number - 800 for example) and see if maxJsonLength error still appears. Also make sure that paging is enabled.

Regards,
Pavlina
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Grid
Asked by
Manish
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Share this question
or