Page 1 of 1
Replace the 0 individually, not in 20, 50, 120...
Posted: Wed Mar 10, 2010 6:16 am
by Lucia
I'm working in a Project where I have several tables with numerical references that I must replace with text. One of these numbers I need to replace is 0, where I need the word "Texto". However, I have many other numbers where 0 appears, such as 20, 50, 120, and and don't want to replace the 0 in these numbers.
Is there a way to replace only the 0, not the 0 in the 20, 50, etc.?
Re: Replace the 0 individually, not in 20, 50, 120...
Posted: Wed Mar 10, 2010 7:04 am
by NorthEast
One solution could be to do a find and replace in the source code.
If you look at the topic in text mode, the zeros might look something like <td>0</td>.
So, you might be able search for >0 and replace with >Texto ; i.e. find only zeros that are at the start of a tag.
In the find and replace pane, you'd also need to need to tick 'Find in source code' option.
Re: Replace the 0 individually, not in 20, 50, 120...
Posted: Wed Mar 10, 2010 8:53 am
by Lucia
Thank you very much

, I don't know why didn't I think of this

, I have used replace in source code many times

Re: Replace the 0 individually, not in 20, 50, 120...
Posted: Wed Mar 10, 2010 9:08 am
by doc_guy
Boa sorte, Lucia! Estamos aqui se vc precisar de ajuda novamente.
(Sorry, I don't get to use my Portuguese very often.)
Re: Replace the 0 individually, not in 20, 50, 120...
Posted: Wed Mar 10, 2010 11:38 am
by Lucia
The fact you speak Portuguese surprises me... Specially the abbreviation for "você"...
Re: Replace the 0 individually, not in 20, 50, 120...
Posted: Thu Mar 11, 2010 11:28 am
by doc_guy
I abbreviated "você" for two reasons: First, I only have US English enabled on my keyboard right now, and second because I wanted it to not look like I just generated it from a computer. By using the abbreviation, you'd know that I hadn't just Googled the Portuguese translation.
I lived in São Paulo from 97-99, which is how I learned Portuguese, because it isn't taught in any school around here that I know of.

Re: Replace the 0 individually, not in 20, 50, 120...
Posted: Fri Mar 12, 2010 4:11 am
by Lucia
Que legal!