🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #16729

Re: Req. for help: Unique page numbering script A1,A2,B1,B2,...

#16729
From: CouponBoy
Date: Tue, 05 Aug 2003 16:41
32 lines
2724 bytes
Hi,
this is a little complex but not impossible. What you are probably going to have to do (at least how I see it) is do a section start on every page. So every page has the black triangle above it in the pages pallet and keeps its own page number when they get reshuffled around. Now I can't really write the script, but you can take a look at what we use here. Make up a quick 8 page doc and run this, see how it does it and you can model a script after it. I think you can use the page "name" function to add the A and B. You will have 2 repeat loops, 1 for A pages that starts on page 1 and then you add 2 to rename the next page, then do a B loop, start on page 2 then add 2 to do page 4, 6, 8 etc.
Chris
chris.paveglio@clippermagazine.com

here is my sectioning start script:
PS you'll need an automatic page number text box on a master page to see the results I think.
-----
tell application "InDesign 2.0.2"
	if exists document 1 then
		display dialog "You can set up for a normal book, or a split run book starting on page 3." buttons {"Cancel", "Page 3", "Normal"} default button 3 with icon 1
		set MyPagesPick to button returned of result

		if MyPagesPick is "Normal" then
			tell document 1
				set myDocPageCount to count of pages
				repeat with B from 1 to myDocPageCount
					set myBodyPages to make section with properties {page start:page B, continue numbering:false, page number style:arabic, page number start:B, name:""}
				end repeat
			end tell
		else if MyPagesPick is "Page 3" then
			tell document 1
				set myDocPageCount to count of pages
				repeat with B from 1 to myDocPageCount
					set myBodyPages to make section with properties {page start:page B, continue numbering:false, page number style:arabic, page number start:B + 2, name:""}
				end repeat
			end tell
		end if

		beep
	end if
end tell
Technical Details
Message-ID: <1dea2159.0@WebX.la2eafNXanI>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-03!sn-xit-01!sn-xit-05!sn-xit-09!supernews.com!newshosting.com!news-xfer2.atl.newshosting.com!diablo.voicenet.com!in.100proofnews.com!in.100proofnews.com!nntp.infostrada.it!newsfeed01.sul.t-online.de!t-online.de!WebX
References: <1dea2159.-1@WebX.la2eafNXanI>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f939a,b25055a1306995cf
X-Google-Attributes: gidf939a,public
X-Google-ArrivalTime: 2003-08-05 10:08:10 PST
From: CouponBoy <chris.paveglio@clippermagazine.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-03!sn-xit-01!sn-xit-05!sn-xit-09!supernews.com!newshosting.com!news-xfer2.atl.newshosting.com!diablo.voicenet.com!in.100proofnews.com!in.100proofnews.com!nntp.infostrada.it!newsfeed01.sul.t-online.de!t-online.de!WebX
Newsgroups: adobe.scripting.indesign
Subject: Re: Req. for help: Unique page numbering script A1,A2,B1,B2,...
Message-ID: <1dea2159.0@WebX.la2eafNXanI>
Date: Tue, 5 Aug 2003 09:41:09 -0700
References: <1dea2159.-1@WebX.la2eafNXanI>
Lines: 48
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit