2X faster development
The ultimate ASP.NET MVC UI toolkit to boost your development speed.
This KB illustrates that to export large amount of data in PivotGrid with JSON export. SolutionBy default, you can export data from pivot component up to 12,000 JSON records. Meanwhile, you can increase the limit by setting the following required properties in Web.config file with maximum limit. Web.config<system.web.extensions> <scripting> <webServices> <jsonSerialization maxJsonLength="2147483647"/> </webServices> </scripting> </system.web.extensions> <appSettings> <add key="aspnet:MaxJsonDeserializerMembers" value="2147483647" /> //…. <httpRuntime maxRequestLength="1073741824" targetFramework="4.5" /> <pages> //… <system.webServer> <security> <requestFiltering> <requestLimits maxAllowedContentLength="1073741824" /> </requestFiltering> </security> </system.webServer>
This code increases the exporting support up to 200,000 records. But, when exporting with styles, the maximum exporting support will be up to 150,000 records. Disabling the exportWithStyle api in the “beforeExport” event provides an option to export up to 200,000 records for all types of exporting (Word, PDF, Excel). Find the following code snippet to disable the exportWithStyle api. JS (beforeExport event for all platforms)<script type="text/javascript"> function exporting (args) { args.exportWithStyle = false; // by default it sets as true. It improves performance on exporting huge data when it sets as false. } </script>
ASP<ej:PivotGrid ID="PivotGrid1" runat="server"> <ClientSideEvents BeforeExport="exporting"/> </ej:PivotGrid>
MVC@Html.EJ().Pivot().PivotGrid("PivotGrid1").ClientSideEvents(clientSideEvents => clientSideEvents.BeforeExport("exporting"))
JS$("#PivotGrid1").ejPivotGrid({ //.. beforeExport: "exporting" });
|
2X faster development
The ultimate ASP.NET MVC UI toolkit to boost your development speed.
This page will automatically be redirected to the sign-in page in 10 seconds.