The NChartPrintExporter can help you print the content of a chart. The following code shows a print dialog, which allows the user to print a chart:
Printing a chart with a print preview |
Copy Code
|
---|---|
NChartPrintExporter printExporter = new NChartPrintExporter(chartView.Content) printExporter.ShowDialog(chartView.DisplayWindow, true); |
To skip the print preview and show the native print dialog directly, use the Print method of the print exporter:
Printing a chart directly |
Copy Code
|
---|---|
NChartPrintExporter printExporter = new NChartPrintExporter(chartView.Content)
printExporter.Print;
|