Copy link to clipboard
Copied
Hello one and all! Im currently using a GREP style to change all my negative figures automatically into it's red colored character style, however it will not include the numebers that appear after the deeecimal point. Does anyone have a solution for this please?
Im currently using -\$\d+
Cheers!
Try this expression:
-\d+(\.|)\d+
I would use -\$?\d+\.?\d*
It should find negative numbers with or without the $ and well as with or without a decimal.
Copy link to clipboard
Copied
Try this expression:
-\d+(\.|)\d+
Copy link to clipboard
Copied
I would use -\$?\d+\.?\d*
It should find negative numbers with or without the $ and well as with or without a decimal.
Copy link to clipboard
Copied
Oh my gosh, so close! Thanks for that. The only thing I need it to include now is the letter after the number, such as the 'M' to represent the Million. Please see here:
Copy link to clipboard
Copied
Oh hang on! It worked, I just cleared the other overrides, your a legend Peter!
Copy link to clipboard
Copied
My expression shouldn't find a trailing letter, but that would be easy enough to add.
Stick a \u? on the end to get -\$?\d+\.?\d*\u? and it will add one uppercase letter if any exists.
This could be further modified to select only certain characters, say M, K, C, B, or T if you like, or to include upper and lowercase.