• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Quark image import script problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Quark image import script problem


  • Subject: Quark image import script problem
  • From: "Dr Digby L. James" <email@hidden>
  • Date: Mon, 20 Oct 2003 00:29:13 +0100

I've been trying to alter a script for importing
images into Quark. This worked perfectly on Quark
4 but appears broken on Quark 5 (in fact, I've
just tried the old script in Quark 4 and that
refuses to work too). Can anyone see what I am
doing wrong? In its simplest form the script is:

tell application "QuarkXPress"
activate
tell picture box 1 of page 1 of document 1
set image 1 to alias "Path:Filename"
end tell
end tell

This fails with an error saying :

QuarkXPress got an error: Folder some object wasn't found.

I get the same result whether or not I include "alias".

The full version is:

--Script to import images into picture boxes in a predefined picture box
--Document already has necessary number of pages
--Each page based on a master page with picture box on
--Still to do: get number of files and script
Quark to create appropriate number of pages
--
set thepath to choose folder with prompt "Choose folder containing TIFFs"
--
--Produces dialogue box to select folder
--
set list_of_items to (list folder thepath without invisibles)
--
--without invisibles removes .DS Store from list
--Creates a list containing all files in folder
--To do: check files are all images - with.tiff
extension - and rewrite list if necessary
--
set NumberOfPages to (count of list_of_items)
--
--Counts number of items in list
--
tell application "QuarkXPress"
activate
repeat with i from 5 to NumberOfPages
set banana to thepath & item i of list_of_items as string
--
--Combines path name and file name
--
tell page i of document 1
tell picture box 1
try
set image 1 to banana
on error
set image
1 to (choose file with prompt "Please select the
file " & (item i of list_of_items))
end try
end tell
end tell
end repeat
end tell

This would give the same error if it were not
trapped. So I always get a dialogue box asking me
to select a file.
--
_________________
Dr Digby L. James
Quinta Press
http://www.quintapress.com
Meadow View
Weston Rhyn
Oswestry
Shropshire
England
SY10 7RN
Phone (44)(0)1691 778659
Mobile (44) (0)7970 678144
Fax (44)(0)1691 777638
_________________
--
_________________
Dr Digby L. James
Quinta Press
http://www.quintapress.com
Meadow View
Weston Rhyn
Oswestry
Shropshire
England
SY10 7RN
Phone (44)(0)1691 778659
Mobile (44) (0)7970 678144
Fax (44)(0)1691 777638
_________________
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Quark image import script problem
      • From: "Bob.Kalbaugh" <email@hidden>
  • Prev by Date: Re: Finder scripting dies
  • Next by Date: screensaver with password and different to default
  • Previous by thread: Re: new style spec for XPress 4.XX
  • Next by thread: Re: Quark image import script problem
  • Index(es):
    • Date
    • Thread