Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Automating library creation in InDesign 2.0

0 views
Skip to first unread message

Shane C. Bell

unread,
Jul 2, 2002, 3:51:29 PM7/2/02
to
I am currently creating a large art library in InDesign 2.0. I currently have over 200 items and can conceivably have upwards of 1500. My question is, does anyone know a script or something easier than placing a piece of artwork and then dragging it into the library? This is a very time-consuming process and I always had problems with the library in 1.0 which makes me hesitant to even try.

Shane Stanley

unread,
Jul 2, 2002, 6:37:58 PM7/2/02
to
in article ef973...@WebX.aaQKaf7vad4, Shane C. Bell wrote:

> My question is, does anyone know a script or something easier than placing a
> piece of artwork and then dragging it into the library?

It's all scriptable:

set thePath to path to startup disk as text
tell application "InDesign 2.0.1"
set theLib to make library with data {full name:(thePath & "Test lib")}
set storedItem to store selection into theLib
set properties of storedItem to {name:"Demo item", description:"This is a
test"}
end tell

--
Shane Stanley, ssta...@myriad-com.com.au

Carl Davaz

unread,
Jul 2, 2002, 7:40:19 PM7/2/02
to
Shane Bell,

I started in on a response and saw that Shane Stanley had already given you a hand. There's a little extra below.

All you have to do is select the object you want to add to the library (which you've already created at a specified path) and run the script.

Sometimes when I do this I go through the extra steps of naming and describing the library elements I'm adding. I included that stuff in my example, below.


set thePath to (path to startup disk) as text
tell application "InDesign 2.0.1"
set myDoc to active document
set theLib to open file (thePath & "Test Lib")
tell myDoc
display dialog "Name the new library object" default answer "NameTheElement"
set theName to text returned of result
display dialog "Describe the new library object" default answer "DescribeTheElement"
set theDescription to text returned of result

set storedItem to store selection into theLib

set properties of storedItem to {name:theName, description:theDescription}
end tell
end tell

To deliver the library asset to the page with a script you would do this:

set thePath to (path to startup disk) as text
tell application "InDesign 2.0"
activate
set myDoc to active document
set theLib to open file (thePath & "Test lib")
tell myDoc
place asset "the_name_of_the_asset_you_want" of theLib on myDoc
end tell
end tell

Thanks,

Carl

Shane C. Bell

unread,
Jul 3, 2002, 1:35:56 PM7/3/02
to
Thanks for the responses so far, I am fairly new at the whole scripting process. I am wondering if the above scenerios will only work with art I have already placed on my pasteboard? I am looking to identify a set of folders on a network containing various pieces of art: Volume 1, art, medical art, [150 icons in this folder]. I then need the script to place each of these pieces of art onto the pasteboard and then into the library. Altogether there are about 25 folders that I need to do this to and that is why I am trying to automate it.
Thanks again for your previous advice!

Shane Stanley

unread,
Jul 4, 2002, 11:25:08 PM7/4/02
to
Yes, that can all be done. You'd have to write a script to loop through
them, open the documents, then copy the contents to libraries. Nothing
particularly difficult.

--
Shane Stanley, ssta...@myriad-com.com.au

Don Picard

unread,
Jul 6, 2002, 7:30:04 AM7/6/02
to
Nothing particularly difficult

Easy for you to say, mate.

<g>

Don

Shane Stanley

unread,
Jul 8, 2002, 7:10:12 AM7/8/02
to
in article ef97...@WebX.aaQKaf7vad4, Don Picard wrote:

> Nothing particularly difficult
>
> Easy for you to say, mate.

Well, most of the time all one has to do is stroll over to the scripting
forum and ask the question. Can't get much easier than that. :-)

--
Shane Stanley, ssta...@myriad-com.com.au

0 new messages