Hi
I been given the below code to export the page as an image
Bitmap image = pdf.ExportAsImage(0, new SizeF(s.Width * zoomfactor, s.Height * zoomfactor), true);
The function is:
public Bitmap ExportAsImage(int pageIndex, SizeF customSize, bool keepAspectRatio);
What is the unit of the customSize? it is pixels or points?
Thanks in advance
Tomer
"At present we do not support exporting pages of the PDF document as images with custom zoom factor using PDF viewer WPF. As a workaround please use the ExportAsImage method in PdfLoadedDocument by providing custom size for an image to export.
Please find the code snippet for your reference.
PdfLoadedDocument pdf = new PdfLoadedDocument("example.pdf");
SizeF s = pdf.Pages[0].Size;
Bitmap image = pdf.ExportAsImage(0, new SizeF(s.Width * zoomfactor, s.Height * zoomfactor), true);
image.Save("output.png");
We have also provided a sample below which exports the page as image with custom size for your reference.
"