I am trying to get the PdfRangeDocument.FromDocument method to work on a Windows Form but whatever I try, it will always show me a page range [1..n] rather than [m..m+n]. If Ι am using the following:
private void pdfViewer1_Load(object sender, EventArgs e)
{
string path = @"D:\tmp\0543_y20_sp_4.pdf";
IPdfDocument _document = PdfDocument.Load(path);
pdfViewer1.Document = PdfRangeDocument.FromDocument(_document, 2, 2);
}
I expect this to show page 2 of the pdf but is just shows page 1. If I change the last line to
pdfViewer1.Document = PdfRangeDocument.FromDocument(_document, 2, 3);
I get pages 1 and 2 displayed.
Am I missing something here?
I am trying to get the PdfRangeDocument.FromDocument method to work on a Windows Form but whatever I try, it will always show me a page range [1..n] rather than [m..m+n]. If Ι am using the following:
I expect this to show page 2 of the pdf but is just shows page 1. If I change the last line to
I get pages 1 and 2 displayed.
Am I missing something here?