Copy link to clipboard
Copied
I have a table with data in it. There is a column "prices" some data is 0 and I want to replace it with - But i also have 0,25 and that has to stay like it is.
So:
0 -> -
0,25 -> 0,25
01 -> 01
000001 -> 000001
I want to replace the single character 0 to - .
What I tried:
REGEX:^^0=-;
This code replaces the first 0 of all the strings so:
0 -> -
0,25 -> -,25 (BUT I want this to stay)
Any ideas?
In tables, try search for ^0$.
Will work for cells, which contain 0 character only.
Not useful for regular text list, though.
Copy link to clipboard
Copied
Well if this is for InDesign purposes surely you should just use a GREP styling to dictate this?
Copy link to clipboard
Copied
any idea how I can do this? I have no experience with GREP
Copy link to clipboard
Copied
This article may provide some hints even though the goal was to do with phone numbers: Formatting phone numbers with GREP​.
I'm also still learning about GREP but I would recommend asking https://forums.adobe.com/people/Obi-wan%20Kenobi (Obi-wan Kenobi) to help you more.
If I figure out how to do it in the mean time I will let you know.
Sorry
Copy link to clipboard
Copied
In tables, try search for ^0$.
Will work for cells, which contain 0 character only.
Not useful for regular text list, though.
Copy link to clipboard
Copied
it worked in indesign tho. Any idea if I can use this in my tables in EasyCatalog?
Copy link to clipboard
Copied
Frankly, I don't use this plugin, and I'm not sure if you can (are allowed to) edit the code somehow...
Copy link to clipboard
Copied
found it THANKKSSS : REGEX:^0$; in easyCatalog! Thank you all
Copy link to clipboard
Copied
Oh, I'm glad you've sorted it out
Copy link to clipboard
Copied
http://indesignsecrets.com/findbetween-a-useful-grep-string.php
It seems like Find/Replace option would be the starting point