Can anyone help on this with Quark 7?
Search and replace from an Excel list, line by line, through 20 separate Quark docs (each Quark doc 32 pages long) and replace new item numbers for Quark from Excel.
I had been doing this by hand ... 5000 items to search and replace on 20 quark docs. Usually takes days. I want to make this script more automated. Can anyone shine a light on how to make this work.
Here is the Quark search / replace script:
display dialog "Search for this number:" default answer "Search"
set searchstring to text returned of result
display dialog "Replace with this number:" default answer "Replace"
set replaceString to text returned of result
tell application "QuarkXPress"
activate
my SearchAndReplace(searchstring & "", replaceString & "")
end tell
on SearchAndReplace(searchString, replaceString)
set sourceFolder to choose folder with prompt "Choose the folder to process."
tell application "Finder" to set theFiles to files of folder sourceFolder whose kind contains "QuarkXPress"
repeat with oneFile in theFiles
tell application "QuarkXPress"
open oneFile
tell document 1
tell every story
set (every text where it is searchString) to replaceString
end tell
end tell
end tell
end repeat
end SearchAndReplace
this works quite well ... but really need some help getting the list line by line out of excel searching the documents and replacing the text with new text.
Thank you in advance for help or suggestions...