PDF document navigation

PDF document navigation

Forum member · Jan 5, 2010
Hello. There is an issue with a page navigation in the DynamicPDFViewer. Steps to reproduce: 1. Open a file containing 10 and more pages in DynamicPDF Viewer; 2. Press the button to navigate to the last page of the document; 3. Press [Zoom Out] (-) several times, until 3 and more pages are displayed at once; 4. Press the button to navigate to the first page of the document; Actual results: View is not changed (there is no jump to first page). Expected results: There is a jump to first page (zoom level still the same as after the 3-rd step).

Re: PDF document navigation

Support · Jan 5, 2010
Hello, We are able to navigate to the first page without any problem by following the steps you have given to recreate the behavior. We did not see any problem. Can you please try using the latest build files downloading from our CustomerArea ? if you are evaluating then you can get the latest files from our website . Thanks, ceTe Software Support Team.

Re: PDF document navigation

Forum member · Jan 6, 2010
In fact it seems that problem is that the code below results in infinite recursion but should not. private ceTe.DynamicPDF.AxViewer.Control.DynamicPDFViewerControl dynamicPDFViewerControl1; private void dynamicPDFViewerControl1_OnPageChange(object sender, EventArgs e) { dynamicPDFViewerControl1.GoToPage(dynamicPDFViewerControl1.CurPage); }

Re: PDF document navigation

Support · Jan 7, 2010
Hello, The method GoToPage will invoke the event OnPageChange and this event code is again calling the GoToPage method which invokes the OnPageChange. So the code you have given will run infinite and may give an error. What exactly is your requirement so that we can help you to achieve your requirement? Thanks, ceTe Software Support Team.

Re: PDF document navigation

Forum member · Jan 11, 2010
My requirement is if the current page number is 1 and I invoke GoToPage(1) then OnPageChange event is not invoked because current page is not changed.

Re: PDF document navigation

Support · Jan 11, 2010
Hello, Can you please be more specific about what kind of requirement you have so that we can help you further? What exactly you want to do by calling the GoToPage(1) method when you are already in page 1? Thanks, ceTe Software Support Team.

Re: PDF document navigation

Forum member · Jan 12, 2010
I just want that OnPageChange event is not called in this case.

Re: PDF document navigation

Support · Jan 12, 2010
Hello, The OnPageChange() event will be fired every time a page change occurs. There is no way to prevent the event from firing in scenario when the GoToPAge(1) is currently the current page. Thanks, ceTe Software Support Team

Re: PDF document navigation

Forum member · Jan 14, 2010
Ok, thank you.