saveAsPDF

    Initiates the PDF export and returns a promise. Also triggers the pdfExport event.

    Calling this method may trip the built-in browser pop-up blocker. To avoid that, call this method as a response to an end-user action, e.g. a button click.

    The pdfExport event handler could be used to dynamically modify the to-be-exported PDF file.

    Returns

    Promise A promise that will be resolved when the export completes. The same promise is available in the pdfExport event arguments.

    Example - manually initiate PDF export

    Open In Dojo
    <button id="export">Export to PDF</button>
    <div id="grid"></div>
    <script>
    $("#grid").kendoGrid({
      columns: [
        { field: "name" },
        { field: "age" }
      ],
      dataSource: [
          { name: "Jane Doe", age: 30 },
          { name: "John Doe", age: 33 }
      ],
    });
    $("#export").click(function(e) {
        var grid = $("#grid").data("kendoGrid");
        grid.saveAsPDF();
    });
    </script>
    In this article