# Print

Learn how to print reports with ActiveReportsJS

## Content

### Print a report with ActiveReportsJS Viewer

ActiveReportJS Viewer component includes `Print` button on the toolbar. Click this button opens the browser print dialog for the current displayed report. In addition, the viewer API exposes [print method](https://developer.mescius.com/activereportsjs/api/classes/ReportViewer.Viewer#print) that can be called to print the current displayed report.

### Print a report programatically

ActiveReportsJS API allows to print a report programmatically. Here is the example of code that loads, runs, and prints a report:

```js
import { Core } from "@mescius/activereportsjs";
const report = new Core.PageReport();
await report.load("/reports/text-only.rdlx-json");
const doc = await report.run();
doc.print();
```

Alternatively a report can be exported to the PDF or HTML document with `autoPrint` option is set to `true`. In that case the print dialog of the document viewer appears when the document is opened. Check [Export page](/activereportsjs/docs/v6.1/DeveloperGuide/ActiveReportsJSViewer/Export) for more information on how to use Export functionality of ActiveReportsJS.

### Related topics

* [Export](/activereportsjs/docs/v6.1/DeveloperGuide/ActiveReportsJSViewer/Export)
* [Pure JavaScript integration](/activereportsjs/docs/v6.1/DeveloperGuide/ActiveReportsJSViewer/Integration/VanillaJS)
* [Angular Viewer Component](/activereportsjs/docs/v6.1/DeveloperGuide/ActiveReportsJSViewer/Integration/Angular-Component)
* [React Viewer Component](/activereportsjs/docs/v6.1/DeveloperGuide/ActiveReportsJSViewer/Integration/React-Component)
* [Vue Viewer Component](/activereportsjs/docs/v6.1/DeveloperGuide/ActiveReportsJSViewer/Integration/Vue-Component)