Expand my Community achievements bar.

Dynamic page numbers for PDF.

Avatar

Level 5

Hi,

How to give starting page number for PDF. If i need to start page number from 3 how can i do this ?

if i need to give randome page number best way to give it?

Following is the example

i have 6 page document.

the page number for the documents should be 3,4,5,9,10,13.

Thanks in advance...!!plz help me ..!! 

8 Replies

Avatar

Level 5

i would like to give exact senario

I have document which has 10 pages.Each page has page number on it...

There are 3 sections.First section is from 1st page to 4th page and second section is from 5th page - 8th page,second section has flowable content.For the second section we might get till 6th page or 7th page or 8th page.If we get till 8th page there will be no problem.If it ends at 7th page the page numbers sequence should be (1,2,3,4,5,6,7,9,10) But section 3 should start from 9th page.

Thanks in Advance

Avatar

Level 7

You should use different master pages for each section and then under Object > Pagination for each master page you can choose what page number that section starts at.

Avatar

Level 5

Thanks alot for you reply ...

Yes i have done that .. But the page number are coming in sequence which is not my requirement ..

Please have a look at my first reply that might help you to understand what exactly i want ..

Please let me know if you need further information..

Avatar

Level 7

Do you want section 3 to always start at page 9? If so just set the master page for that section to start at 9. If not, do you want random numbers or is there some sort of logic behind what you want?

Avatar

Level 5

I appreciate your help.

Yes, it should start form page 9.

If so just set the master page for that section to start at 9? I have been trying  to implement this ...  Could you help me with the script to implement the it.

Avatar

Level 7

In your master page for section 3 place a floating field and then in the layoutReady event for that field put (in javascript):

this.rawValue = section3.index + 9

(replacing "section3" with whatever you have called that masterpage)

Avatar

Level 5

Thanks for your reply.

I tried the logic bt im facing the following issues.

Only 9 th page will get page number 9.

How about the 10th page and so on?

Do we need to give separate subform for those?

Avatar

Level 7

No you dont need a seperate section. The index part of the formula will increase the page numbers. The index of the first page in the section is 0 so 0 + 9 = 9 which is the first page, and then the next one will be 1 + 9 = 10, and so on.