BoldDeskWe are launching BoldDesk on Product Hunt soon. Learn more & follow us.
Hi Harry,
In our ASP.NET MVC Treegrid, we have rendered all the html elements in clientside and we have passed the data to the control from serverside to clientside as Json data by serializing it. And we have used the defaultMaxJsonLengthvalue (2097152characters, which is equivalent to 4MB of Unicode string data) of the JavaScriptSerializer which is a fixed universal standard length for serializing the data, in our implementation.
So we have to create a custom serializer to serialize the data Source if the data exceeds its limit, this can be done as follows.
using Newtonsoft; using Syncfusion.JavaScript.Shared.Serializer; //… public ActionResult Index() { var DataSource = GanttDataSource.GetData(); DataManagerConverter.Serializer = new DMSerial(); ViewBag.datasource = DataSource; return View(); } //… public class DMSerial: IDataSourceSerializer { public string Serialize(object obj) { var str = Newtonsoft.Json.JsonConvert.SerializeObject(obj); return str; } } |
We have also prepared a sample based on this and you can find the sample under the following location:
Sample: http://www.syncfusion.com/downloads/support/forum/119571/ze/LargeData888429426
Please let us know if you need further assistance on this.
Regards,
Mahalakshmi K.