Applescript Case Study
Inspyre recently finished an an Applescript development project.
Project Motivation:
We begin with a product catalog containing several thousand individual item entries, in the format of many Adobe InDesign documents. Most catalog entries consist of a small thumbnail picture of a book, followed by some product meta data including pricing information and a 10 digit ISBN number. A price update has been released and the catalog needs to be updated.
Project Objective:
Use the programming/scripting language Applescript to automate the process of updating all catalog entries with the appropriate 13 digit ISBN number, found in the Excel spreadsheet.
Project Details:
The price update is in the from of a Microsoft Excel spreadsheet with thousands of rows, each row representing an updated item in the catalog. Column C in the spreadsheet contains the 10 digit ISNB number for the row-record, another column potentially contains a footnote symbol to follow the updated price (a small cross symbol). If no symbol is present in the column then an invisible asterisk should be inserted for spacing purposes.
Deliverable
(****************************************
** ISBN Price Replacer v.1.3
**
** Copyright: 2007 inspyre LLC
** Date: 3 August 2007
** Updated: 28 August 2007 to look up 10 digit isnb numbers now
*****************************************)set ISBN_GROSS_LENGTH to 13
set BEFORE_DOLLAR_LENGTH to 33
set ISBN_10_COLUMN to “C”
set DEBUG_MODE to 0 — 1 = no debugging, 1 = high level loops, 2 = low level loops
set USER_FRIENDLY to true
set TEXT_COLOR to “Black”
set SPACER_COLOR to “None”
–set SPACER_COLOR to “C=0 M=100 Y=100 K=0″
set LOG_FILE to true
set LOG_FILE_NAME to “Price Replacer log.txt”
(more…)
