• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Help Please!! Script for table needed.

New Here ,
Mar 04, 2010 Mar 04, 2010

Copy link to clipboard

Copied

Hi,

I'am formating a table in Indesign with figure in the cell like for example $(123.45) and theres a lot if it. I need to separate or move the $ sign to previous column and the closing parenthesis to the next column. What I do is to insert new column before and after then copy and paste the $ to previous column and the parenthesis to the next. Is there anyone knows to automate this using script.

Thanks,

DennisM

TOPICS
Scripting

Views

647

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
Community Expert ,
Mar 05, 2010 Mar 05, 2010

Copy link to clipboard

Copied

dennismacaburas wrote:

I'am formating a table in Indesign with figure in the cell like for example $(123.45) and theres a lot if it. I need to separate or move the $ sign to previous column and the closing parenthesis to the next column. What I do is to insert new column before and after then copy and paste the $ to previous column and the parenthesis to the next. Is there anyone knows to automate this using script.

If your tabel isn't too complicated you can use this workaround:

1) convert table to text with TAB separator

2) replace "^t$(" to "^t$^t("

3) replace ")" to "^t)"

4) convert text to table

But what with "(" ?

Do you want to have this:

$ | (123.45 | )

or

$( | 123.45 | )

robin

www.adobescripts.com

Votes

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 07, 2010 Mar 07, 2010

Copy link to clipboard

Copied

Thank you for the reply. This actually works. Another problem that came up. When the following row don't have $ sign the figure was align in the $. My document should look like this in table for you to see.

$    |  (1234.45  | )

      |   1234.45  |

      |  (1234.45  | )

$    |   1234.45 |

I hope you help me again in this one.

Thanks,

DennisM

Votes

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
Community Expert ,
Mar 07, 2010 Mar 07, 2010

Copy link to clipboard

Copied

hi Dennis,

Could you please attach small screen shoots - before and after ? Just for clarification.

robin

www.adobescripts.com

Votes

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 08, 2010 Mar 08, 2010

Copy link to clipboard

Copied

Hi Robin,

Here is the before and after sample table.

sample.JPG

Thanks,

Dennis

Votes

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
Community Expert ,
Mar 09, 2010 Mar 09, 2010

Copy link to clipboard

Copied

dennismacaburas wrote:

Hi Robin,

Here is the before and after sample table.

I think it should be easy to achieve by GREP - if you have CS3 or CS4.

I'll try to prepare GREP expressions

robin

www.adobescripts.com

Votes

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
LEGEND ,
Mar 09, 2010 Mar 09, 2010

Copy link to clipboard

Copied

Ummm.

Why don't you just use a decimal align on those numbers instead of creating all those extra cells?

http://forums.adobe.com/thread/587552?tstart=0

Harbs

Votes

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
Community Expert ,
Mar 09, 2010 Mar 09, 2010

Copy link to clipboard

Copied

Harbs. wrote:

Ummm.

Why don't you just use a decimal align on those numbers instead of creating all those extra cells?

http://forums.adobe.com/thread/587552?tstart=0

Good point But maybe he need to "$", "(" and ")" always at the same place ?

robin

www.adobescripts.com

Votes

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 09, 2010 Mar 09, 2010

Copy link to clipboard

Copied

LATEST

The "$" and the ")" really should be in separate cell.

Votes

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