Print Page | Close Window

CopyPageRanges does not follow page order

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=2335
Printed Date: 04 Apr 26 at 4:48AM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: CopyPageRanges does not follow page order
Posted By: JanN
Subject: CopyPageRanges does not follow page order
Date Posted: 13 Jul 12 at 1:07PM
Hello,

I have a document containing 10 pages. I call CopyPageRanges(DocumentID, '1,5,4,3,2,6,10,9,8,7'). The pages are copied but still are in original order.

Can anyone please confirm or disprove my problem with CopyPageRanges?

Regards,
Jan



Replies:
Posted By: jpbro
Date Posted: 13 Jul 12 at 3:35PM
According to the documentation, that is the designed behaviour:

"The list of pages will be sorted resulting in the pages being extracted in numerical order. "

http://www.quickpdflibrary.com/help/quickpdf/CopyPageRanges.php - http://www.quickpdflibrary.com/help/quickpdf/CopyPageRanges.php


Posted By: JanN
Date Posted: 13 Jul 12 at 3:47PM
But it definitely worked in previous versions of QuickPDF. I hope that the programmers of QuickPDF can confirm this.


Posted By: Ingo
Date Posted: 13 Jul 12 at 5:36PM
Hi Jan!

i think Jopbro is right.
For what you wanna do you should use the move-functionalities.

Cheers, Ingo


Posted By: JanN
Date Posted: 17 Jul 12 at 1:15PM
Maybe it always worked this way in the "new" QuickPdf library. But I am quite sure that it worked differently in the original library. Until a few days ago I still used version 7.18 in one of my projects and it worked. Are you absolutely sure that there were no changes made in the meantime? And when there are such changes, what was the intention to do so? I think maintaining the given page order was the better approach. ;)

If I use the current functionality, I have little problems getting the pages into the right order. I have a string "1,5,4,3,2,6,10,9,8,7". When I call CopyPageRanges I get a document containing the pages "1,2,3,4,5,6,7,8,9,10". When I now want to move page after page, I sometimes have to increase following page numbers and sometimes not. Does somebody have a code snippet for this topic?


Posted By: AndrewC
Date Posted: 17 Jul 12 at 2:23PM
CopyPageRanges was changed to sort pages back in QPL 7.21 - That is just before my time so I don't know the reasons why.

I have just confirmed that the documentation was changed in 7.21 because that was the way the function was working and the only way it could work without having write lots more code to reorder pages.

Andrew.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk