Question

I'm trying to print the contents of a canvas with some other UI elements but having very limited success. Is there any way to construct the elements to a Grid for example instead, then print the contents rendered at a desired page size?

This was, I could get the benefit of databinding and vastly easier layout without using System.Windows.Documents.

Was it helpful?

Solution

Take a look at this good short article called Printing WPF window(visual) to printer and fit on a page. It shows the basics of printing in WPF, but also how to size the visual to fit the page.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top