SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and now iOS Charting & Android Chart Components

0
0

Hello,

I would like to know if there is a possibility to export 3d charts to XPS format. I’ve tried using ExportToFile extension method:
sciChart.ExportToFile(filePath, ExportType.Xps, true);

While this method works well on 2d chart, it throws an exception:

InvalidCastException: Unable to cast object of type ‘SciChart.Charting3D.SciChart3DSurface’ to type ‘SciChart.Charting.Visuals.SciChartSurface’.

Stack Trace:
at SciChart.Charting.Visuals.SciChartSurfaceBase.CreateCloneOfSurfaceInMemory(Size newSize)
at SciChart.Charting.Visuals.SciChartSurfaceBase.ExportToFileInternal(String fileName, ExportType exportType, Boolean useXamlRenderSurface, Nullable`1 size)
at SciChart.Charting.Visuals.SciChartSurfaceBase.ExportToFile(String fileName, ExportType exportType, Boolean useXamlRenderSurface)

It suggests there is no way to export 3d charts, am I correct?

Version
v4.0.30319
  • You must to post comments
0
0

Hi Wojchiech,

Exporting a 3D Chart to XPS is not going to be possible, because the 3D Chart is drawn using DirectX (not vector primitives).

We would suggest instead to export to PnG or Bitmap and embed the result into an XPS document.

If you require further assistance, open a support ticket and we’d be glad to show you how.

Best regards,
Andrew

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.