# Export

This topic illustrates how to export an RDLX or Page report to different export formats, such as PDF, XLSX, JSON, MHT and CSV, using code in ActiveReports.

## Content



This sample illustrates how to export to different export formats using code. The available export formats are PDF, XLSX, CSV, DOCX, MHT and JSON.

![Exporting Types](https://cdn.mescius.io/document-site-files/images/b298aea2-8cb8-4a0f-be88-4f54aa263ebd/images/exportpagerdl-sample.png)<br />

### Sample Location

**Visual Basic.NET**

[https://github.com/activereports/Samples19/tree/main/API/PageAndRDLX/Export/VB.NET](https://github.com/activereports/Samples19/tree/main/API/PageAndRDLX/Export/VB.NET)

**C#**

[https://github.com/activereports/Samples19/tree/main/API/PageAndRDLX/Export/C#](https://github.com/activereports/Samples19/tree/main/API/PageAndRDLX/Export/C%23)

### Details

When you run this sample, the Export Form is displayed. The Export Form contains the **Report Name** and **Export Type** combo boxes along with the **Export** button.

The sample consists of **ExportForm**. It exports the selected report in the selected export format.<br />On running the application, select a report for export in the **Report Name** combo box. In the **Export Type** combo box, you can select one of the following formats for export - PDF, XLSX, CSV, DOCX, MHT and JSON. Clicking the **Export** button opens the **Save As** dialog where you can specify the name of the exported file. By default, the exported file is saved in the **Documents** folder.