• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Replace Function...What if there are duplicate letters?

PP3321

Active Member
I want to insert ' (apostrophe) in front of letter E in the string.

E10A10E10
↓↓↓
'E10A10'E10

The following code will only add apostrophe in the 1st occurrence.

=REPLACE(A1,SEARCH("E",A1),0,"'")

Is there a way to insert apostrophe to every occurrence of letter E within the string...?

Thank you...
 
Last edited:
I want to insert ' (apostrophe) in front of letter E in the string.

E10A10E10
↓↓↓
'E10A10'E10

The following code will only add apostrophe in the 1st occurrence.

=REPLACE(A1,SEARCH("E",A1),0,"'")

Is there a way to insert apostrophe to every occurrence of letter E within the string...?

Thank you...
Hi,
Try this
=SUBSTITUTE(A1,"E","'E")

Thanks & Regards,
CMA Vishal Srivastava
 
Back
Top