<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Search&#x2F;Replace with REGEX capturing groups]]></title><description><![CDATA[<p dir="auto">Hello,</p>
<p dir="auto">How can I use the content of a Regex capturing group in my replacement string when doing a search and replace with Notepad++?</p>
<p dir="auto">Thanks!</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/22555/search-replace-with-regex-capturing-groups</link><generator>RSS for Node</generator><lastBuildDate>Wed, 22 Jul 2026 13:46:23 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/22555.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 12 Feb 2022 05:18:50 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Search&#x2F;Replace with REGEX capturing groups on Sat, 12 Feb 2022 11:04:59 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/benevolent-deity" aria-label="Profile: benevolent-deity">@<bdi>benevolent-deity</bdi></a> said in <a href="/post/74084">Search/Replace with REGEX capturing groups</a>:</p>
<blockquote>
<p dir="auto">How can I use the content of a Regex capturing group in my replacement string when doing a search and replace with Notepad++?</p>
</blockquote>
<p dir="auto">To use capture group 1, put <code>\1</code> or <code>$1</code> or <code>${1}</code> in your replacement string.  Similar for other numbered capture groups.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/74088</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/74088</guid><dc:creator><![CDATA[Alan Kilborn]]></dc:creator><pubDate>Sat, 12 Feb 2022 11:04:59 GMT</pubDate></item><item><title><![CDATA[Reply to Search&#x2F;Replace with REGEX capturing groups on Sat, 12 Feb 2022 06:55:39 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/benevolent-deity" aria-label="Profile: benevolent-deity">@<bdi>benevolent-deity</bdi></a> said in <a href="/post/74084">Search/Replace with REGEX capturing groups</a>:</p>
<blockquote>
<p dir="auto">How can I use the content of a Regex capturing group in my replacement string when doing a search and replace with Notepad++?</p>
</blockquote>
<p dir="auto">First thoughts are that you should be learning how regex is coded, hence go to the FAQ section and take the web links to documents that can help. Secondly, how about looking at some of the posts in this forum. You will find some simple regex, more complicated ones and others that you should not try to understand until you have the basics sorted.</p>
<p dir="auto">As your question was not specific enough, that’s all the help I can provide.</p>
<p dir="auto">If you supply specific examples that you need help on, someone will give that help. Read the pinned posts which explain how examples should be provided.</p>
<p dir="auto">Terry</p>
<p dir="auto">In short, each capture group is assigned a number, which increases, such as 1,2,3 etc. In the replacement field each is referenced like \1,\2,\3 etc but as I say, try to learn it from the reference links.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/74085</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/74085</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Sat, 12 Feb 2022 06:55:39 GMT</pubDate></item></channel></rss>