从<&gt中的单元格中删除所有内容。在Google表中

发布于 2025-01-30 13:51:11 字数 575 浏览 5 评论 0原文

我知道有关从Google Sheets单元格中删除字符的主题很多。我试图找到一种方法来解决我在Web / stackoverflow上的信息中解决问题的方法,但是我找不到它...

我需要在多个行中创建一个带有文本的列。原始文件仍然具有样式代码< p> < strong> < i>等。我需要删除这些样式代码。因此,实际上,每个<>应从单元格中删除代码。我试图用替代品来做到这一点,但我只能说fe删除< p>,而我仍然在工作表中有其他样式代码。

我认为这可以通过 Regexreplace 来完成,但我无法正常工作。我希望有人可以帮助我了解如何使这项工作。谢谢你!

“摆脱“ 的事情

I know there are a lot of topics about removing characters from Google Sheets cells. I've tried to find a way how to solve my issue with the information on the web / stackoverflow but I can't find it...

I need to create a column with text in multiple rows. The original file still has styling codes <p> <strong> <i> etc in it. I need to remove these styling codes. So actually every <> code should be removed from the cell. I tried to do this with substitute but than I can only say f.e. remove <p> and I'm still having the other styling codes in the sheet.

I think this could be done with REGEXREPLACE but I cant get it working. I hope that someone can help me to understand how I can get this working. Thank you!

Overview of things to get rid of

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

伏妖词 2025-02-06 13:51:11

使用:

=ARRAYFORMULA(REGEXREPLACE(D2:D, "<.*?>", ))

在某些情况下,这是不够的:

=ARRAYFORMULA(REGEXREPLACE(D2:D, "<\/\w+>|<\w+.*?>", ))

在某些情况下,即使是不够的,也不足够:

=ARRAYFORMULA(REGEXREPLACE(D2:D, "</?\S+[^<>]*>", ))

use:

=ARRAYFORMULA(REGEXREPLACE(D2:D, "<.*?>", ))

in some cases that wont be enough so:

=ARRAYFORMULA(REGEXREPLACE(D2:D, "<\/\w+>|<\w+.*?>", ))

and in some cases even that wont be enough so:

=ARRAYFORMULA(REGEXREPLACE(D2:D, "</?\S+[^<>]*>", ))
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文