Bring to front

118 views
Skip to first unread message

Andrew Brown

unread,
Jul 5, 2012, 5:31:13 AM7/5/12
to indesi...@googlegroups.com
I have several hundred similar pages, all based on the one master, each has three text frames and each frame has an object style applied. I want to bring all objects of a certain style to the front. Is this possible?

Bringing them to the front on the master page and then applying the master to the pages has no effect. Do I need a script?

AB

Christophe Dhélin

unread,
Jul 5, 2012, 5:46:11 AM7/5/12
to indesi...@googlegroups.com
Hi,
maybe the layers are the solution


Christophe Dhélin

--
you are subscribed to "InDesign talk" on Google Groups, to post: send email to indesi...@googlegroups.com, to unsubscribe: send email to indesign-tal...@googlegroups.com, for more options visit http://groups.google.com/group/indesign-talk

Roy McCoy

unread,
Jul 5, 2012, 6:59:05 AM7/5/12
to indesi...@googlegroups.com
Andrew B.:

> I have several hundred similar pages, all based on the one master, each has three text frames and each frame has an object style applied. I want to bring all objects of a certain style to the front. Is this possible?

In all probability, yes.

> Bringing them to the front on the master page and then applying the master to the pages has no effect. Do I need a script?

Not if Christophe's layers suggestion works for you. I've never scripted anything involving object styles before, but didn't have much trouble putting the following together in AppleScript for a general case:

tell application "Adobe InDesign CS5.5"
set find object preferences to nothing
set applied object style of find object preferences to "[name of your style]"
set theFinds to find object document 1
repeat with j from (count of theFinds) to 1 by -1
bring to front item j of theFinds
end repeat
set find object preferences to nothing
end tell


Roy

Michel Raj

unread,
Jul 5, 2012, 7:31:12 AM7/5/12
to indesi...@googlegroups.com
A script can do it... but a script must be done.
I'm looking at it, in AppleScript, there's a "Bring to front" function that could do it.

Like this for instance :
where you change AndrewBrown into your object style
and CS5 into your version of Indy

tell application "Adobe InDesign CS5"
tell document 1
set myStyle to object style "AndrewBrown"
set myObjects to every text frame whose applied object style is myStyle
repeat with anObject in myObjects
bring to front anObject
end repeat
end tell
end tell


Le 5 juil. 2012 à 11:31, Andrew Brown a écrit :

Andrew Brown

unread,
Jul 5, 2012, 2:41:56 PM7/5/12
to indesi...@googlegroups.com
Thanks to Michel and Roy. I'm on CS5, so have not tried Roy's 5.5 script. Michel's script gives an error:

Error Number -1728... Can't get objet style "CLnotedroite" of document 1...

And if I do a manual search for the object it finds the first few, those that I have already brought to the front, but none of the others. Looks like a bug to me, though of course that's quite impossible in an Adobe product.

AB

Roy McCoy

unread,
Jul 5, 2012, 2:44:43 PM7/5/12
to indesi...@googlegroups.com
You can change 5.5 to 5 in the script and run it in CS5, I suppose.

Roy



On Jul 5, 2012, at 8:41 PM, Andrew Brown wrote:

> Thanks to Michel and Roy. I'm on CS5, so have not tried Roy's 5.5 script. [...]

Michel Raj

unread,
Jul 5, 2012, 5:32:00 PM7/5/12
to indesi...@googlegroups.com
Is your document opened and only the document you want to change ?
Are you sure CLnotedroite is the correct style name ?
I tried the script before sending it, BUT I didn't use master pages.

Would be easier to try to see what's could be wrong with a sample of your document, (2 pages)

Or try and change Roy's script, replacing CS5.5 into CS5... and adding the correct style name.

Michel

Michel Raj

unread,
Jul 5, 2012, 5:40:00 PM7/5/12
to indesi...@googlegroups.com
Oh, and check on your master pages if none of the blocks are locked.
If so, select them and unlock them (cmd-alt-L).

Le 5 juil. 2012 à 20:41, Andrew Brown a écrit :

Bret Perry

unread,
Jul 5, 2012, 9:07:25 PM7/5/12
to indesi...@googlegroups.com
On 7/5/12 2:40 PM, "Michel Raj" <mr...@mac.com> wrote:

>Oh, and check on your master pages if none of the blocks are locked.
>If so, select them and unlock them (cmd-alt-L).

? I suppose a script would do itŠ but it looks to me like it is not
working on master-page items that are still linked to the master -- it
found those that were already in front, and I'm guessing those in-front
Master Page items were also already "Over-ridden" from Master?

In my experience, it is easier to make a special layer above all others
for use only on the master page -- I call it "Master Page Items on top" --
because normally (without over-riding them) no master page item can ever
be above the "plain" page items that are on the same layer as the Master
Page items. But if you put them on a higher layer than the page items,
then they can be above.

That way the master-page item stays linked to the master, and you can
change it by changing the master.

Bret Perry
Studio IT Manager/Production Artist
ph 626-463-9365
fax 626-449-2201
bpe...@russreid.com


The information in this email is confidential and may be legally privileged. It is intended solely for the addressee. Access to this email by anyone else is unauthorized. If you are not the intended recipient, any disclosure, copying, distribution, or any action taken or omitted to be taken in reliance on it, is prohibited and may be unlawful. If you have received this email in error, please notify us immediately by calling the Help Desk at 866-682-8852.

Please consider the environment before printing this email.

Andrew Brown

unread,
Jul 12, 2012, 2:50:40 AM7/12/12
to indesi...@googlegroups.com
Thanks for the help on this subject, in the end I did it my hand. It looks as if I shall have to master layers... -- AB
Reply all
Reply to author
Forward
0 new messages