Welcome Dialog

Welcome to the Community!

We have a brand new look! Take a tour with us and explore the latest updates on Adobe Support Community.


Percentage calculation and save to conditional text

New Here ,
Mar 18, 2021 Mar 18, 2021

Copy link to clipboard

Copied

Hi to all. I would like ask for help in this situation. I have a book with about 300 pages. Each page has many numbers (prices). I have to calculate each selected number by 1% (num*1,01) and maybe round that number at two places up. And the result save as the condition text. Can someone please help me write a script that could do this? Thank you for any help.

TOPICS
How to, Scripting

Views

95

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Advocate , Mar 18, 2021 Mar 18, 2021
1. Create two Conditional Text. 100Price, 101Price 2. Do a GREP Search to match all price, change to to create duplicate of them 3. Do a GREP Search to match the first instance of the duplicate and apply 100Price condition 4. Do a GREP Search to match the second instance of the price and apply 101Price condition 5. Hide 100Price condition 6. Run PriceAdjuster from Peter Kahrel Done! If you need help writing the 3 GREP for this, come back with a screen capture with hidden charcater of your pric...

Likes

Translate

Translate
Adobe Community Professional ,
Mar 18, 2021 Mar 18, 2021

Copy link to clipboard

Copied

Peter Kahrel has already written something like this. Check his script out here:

 

https://creativepro.com/files/kahrel/indesign/price_adjuster.html

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Mar 18, 2021 Mar 18, 2021

Copy link to clipboard

Copied

1. Create two Conditional Text. 100Price, 101Price
2. Do a GREP Search to match all price, change to to create duplicate of them
3. Do a GREP Search to match the first instance of the duplicate and apply 100Price condition
4. Do a GREP Search to match the second instance of the price and apply 101Price condition
5. Hide 100Price condition
6. Run PriceAdjuster from Peter Kahrel

Done!

If you need help writing the 3 GREP for this, come back with a screen capture with hidden charcater of your price. Or how the price is written.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Mar 18, 2021 Mar 18, 2021

Copy link to clipboard

Copied

LATEST

Thank you. Process which Jean-Claude wrote will work fine for me. Once more all of you thanks!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines