Skip navigation
Stancaines
Currently Being Moderated

Help me remove Zeroes and add Decimal point using GREP Expression

Apr 19, 2012 7:09 AM

Tags: #cs5 #mac #indesign_cs5 #grep

Hello, I have some numbers. . . A few thousands to be exact that I need to drop some zeroes and add a dollar sign and decimal point representing the cents, how do I do that using GREP Expression. An example of the number would be: 000000000396465 or 000000000044813, it will always be 15 characters I would like that to be converted to this:

$3964.65

$448.13

 

Thank you

Am using Adobe CS5 On Mac

 
Replies
  • Currently Being Moderated
    Apr 19, 2012 7:20 AM   in reply to Stancaines

    This will do the job:

     

    Find what: \<([0]+(?=[1-9]))(\d+)(\d{2})\>

     

    Change to: $$2.$3

     

    HTH

     

    --

    Marijan (tomaxxi)

    http://tomaxxi.com

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 19, 2012 7:33 AM   in reply to Stancaines

    You are welcome!

     

    --

    Marijan

     
    |
    Mark as:
  • Currently Being Moderated
    May 9, 2012 7:41 AM   in reply to Stancaines

    Try:

     

    Find (?<=\d)\u   (presuming company names all start with uppercase)

     

    Change <spacebar>$0

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points