RE: Converting Pounds Prices to Euro Prices
RE: Converting Pounds Prices to Euro Prices
- Subject: RE: Converting Pounds Prices to Euro Prices
- From: "Alex Husted" <email@hidden>
- Date: Mon, 19 Feb 2007 14:23:22 -0500
- Thread-topic: AppleScript-Users Digest, Vol 4, Issue 79
David,
What you really need is a regular expression find/replace. Since Quark and InDesign don't have this built in you have a few options.
1. Run the regexp replace through a text editor app like BBEdit.
2. Do the regexp replace as a shell script.
3. Install the Satimage.osax scripting addition and do it right in your script.
I have successfully used both 1 and 3 for various similar tasks. All of these solutions have their ups and downs, but once you learn how to use regular expressions you won't know how you lived without them.
Alex
Date: Mon, 19 Feb 2007 10:08:28 +0000
From: David Bradley <email@hidden>
Subject: Converting Pounds Prices to Euro Prices
To: Applescript Mailing List <email@hidden>
Message-ID: <email@hidden>
Content-Type: text/plain; charset=WINDOWS-1252; delsp=yes;
format=flowed
Hi,
Have trouble finding any help on how to convert prices in pounds to
euros, has anyone done this before or give me any clues.
I have a text box in a Quark XPress document that contains several
prices in pounds sterling.
I would like to write a script that will look for those prices and
convert them into euros.
I have managed to search the text box and change the '£' symbol to
'EUR' with the following script:
tell application "QuarkXPress"
tell front document
tell every text box of page 1
if (exists (every text where it is (ASCII character 163))) of
every text then
set (every text where it is (ASCII character 163)) to (ASCII
character 219)
end if
end tell
end tell
end tell
This e-mail and any files transmitted with it are intended solely for
the use of the addressee. This e-mail may contain confidential and/or
legally privileged information. Any review, transmission, disclosure,
copying, or any action taken or not taken, by other than the intended
recipient, in reliance on the information, is prohibited. If you
received this e-mail in error, notify the sender and delete this e-mail
from your computer and network. In addition, please be advised that
Edmund Optics reserves the right to monitor, access and review all
messages, data and images transmitted through our e-mail system. By
using our e-mail system, you consent to this monitoring.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/mailman//archives/applescript-users
This email sent to email@hidden