ASPxGridBase.ExportPdfToResponse() Method
Exports the grid’s data to the specified file in PDF format with the specified settings, and writes it to the response in binary format.
Namespace: DevExpress.Web
Assembly: DevExpress.Web.v26.1.dll
NuGet Package: DevExpress.Web
Declaration
Remarks
This method writes files to the response and do not write them to storage (for example, a file system).
<dx:ASPxGridView ID="ASPxGridView1" runat="server" DataSourceID="CustomerReportsDataSource" />
<dx:ASPxButton ID="ASPxButton1" runat="server" Text="Export to XLS" OnClick="ASPxButton1_Click" />
protected void ASPxButton1_Click(object sender, EventArgs e) {
ASPxGridView1.ExportPdfToResponse();
}
See Also