Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Add prices with taxes in quark



Title: Re: Add prices with taxes in quark
At 5:49 PM +0200 7/27/06, Jan Bultereys wrote:
Hi,

Is there a way to add prices with taxes (21%)  after an existing price in quark 6.5?
Let's say I have an example like this:
Product  price1 price2 price3
Paper      10       20        30

And I want to have this:
Product    price1          price2        price3
Paper     10 (12.1)     20 (24.2)    30 (36.3)

Any help is much appreciated
Jan

I don't have Quark, but assuming you can 'grab' a line of the text, that the price could have one place after the decimal point, and that you want only one place after the decimal point of the price with tax added, this script will do it:

set aPriceLine to "Paper      11.1       22.2        33.3" as Unicode text
set w to words of aPriceLine
repeat with k from 2 to count w
  
tell item k of w to set T to it & space & "(" & ((12.1 * it) as integer) / 10 & ")"
    
set item k of w to T
end repeat
w
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-users/email@hidden

This email sent to email@hidden

References: 
 >Add prices with taxes in quark (From: Jan Bultereys <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.