0

I would like to get rid of "$" in several cells. A cell contains f.e. "$q$3", but I would to change it into "Q3"

How to fix this with function regexreplace?

Anyone? Thanks for helping!

  • 1
    Since `$` is a usually special character in regex, it must be escaped with a preceding backslash in order to match it. it would be helpful to provide more detail about the context of your question (e.g. is this Excel or Google sheets, or something like that?, then add the appropriate tag). Also, you should show us what you've attempted and what results you got. – Paul Dempsey May 10 '23 at 20:05

1 Answers1

3

Well it depends in what language your coding, hence the remark of Mr. Paul Dempsey.

Here's a link that deals with removing special characters with c#, and here's one from microsoft.learn:

using System.Text.RegularExpressions;

string input = "$q$3";
      string pattern = "\$";
      string replacement = "";
      string result = Regex.Replace(input, pattern, replacement);

if you type in regex and tools in a search engine you'll find plenty of tools and here's an on-line .Net compiler

If this answer helps you, plz give Mr. Dempsey's remark an upvote. Thank you.

Any typo's, obvious mistakes, ... . Plz be so kind to post a remark to improve the answer.

qqtf
  • 632
  • 6
  • 17