<?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[ADD A LINE AT THE END]]></title><description><![CDATA[<p dir="auto">Hello, I am novice to NotePad.</p>
<p dir="auto">I would need to add a new line of text after certain lines already present (not all of them).</p>
<p dir="auto">I tried with:<br />
Find what: $<br />
Replace with: \r</p>
<p dir="auto">But in this way he adds a new line to me at the end of all the lines already present.</p>
<p dir="auto">How could I do that? Thank you very much!</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/22785/add-a-line-at-the-end</link><generator>RSS for Node</generator><lastBuildDate>Wed, 19 Aug 2026 11:08:18 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/22785.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 30 Mar 2022 10:40:39 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to ADD A LINE AT THE END on Wed, 30 Mar 2022 14:19:04 GMT]]></title><description><![CDATA[<p dir="auto">Hi, @memytim19,</p>
<p dir="auto">Just look <a href="https://community.notepad-plus-plus.org/post/32248">here</a> for <strong>documentation</strong></p>
<p dir="auto">BR</p>
<p dir="auto">guy038</p>
]]></description><link>https://community.notepad-plus-plus.org/post/75596</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/75596</guid><dc:creator><![CDATA[guy038]]></dc:creator><pubDate>Wed, 30 Mar 2022 14:19:04 GMT</pubDate></item><item><title><![CDATA[Reply to ADD A LINE AT THE END on Wed, 30 Mar 2022 12:25:50 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/guy038" aria-label="Profile: guy038">@<bdi>guy038</bdi></a> Thank you very much, it’s perfect, I still have a lot to learn</p>
]]></description><link>https://community.notepad-plus-plus.org/post/75591</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/75591</guid><dc:creator><![CDATA[Memole1990]]></dc:creator><pubDate>Wed, 30 Mar 2022 12:25:50 GMT</pubDate></item><item><title><![CDATA[Reply to ADD A LINE AT THE END on Wed, 30 Mar 2022 14:20:04 GMT]]></title><description><![CDATA[<p dir="auto">Hello, @memytim19 and <strong>All</strong>,</p>
<p dir="auto">Well, it depends on the <strong>location</strong> where you want to insert this <strong>new</strong> line :</p>
<ul>
<li>
<p dir="auto">If you want to insert this <strong>new</strong> line at the <strong>very end</strong> of current file :</p>
<ul>
<li>
<p dir="auto">SEARCH <strong><code>\z</code></strong></p>
</li>
<li>
<p dir="auto">REPLACE <strong><code>\r\n</code></strong></p>
</li>
</ul>
</li>
<li>
<p dir="auto">If you vant to insert this <strong>new</strong> line <strong>after</strong> the <strong><code>Nth</code></strong> <strong>first</strong> lines of current file</p>
<ul>
<li>
<p dir="auto">SEARCH  <strong><code>(?-s)\A((?:.*\R){</code>N<code>})</code></strong></p>
</li>
<li>
<p dir="auto">REPLACE <strong><code>\1\r\n</code></strong></p>
</li>
</ul>
</li>
<li>
<p dir="auto">If you want to insert this <strong>new</strong> line <strong>after</strong> the line ( or <strong>each</strong> line ) containing the named string <strong>String</strong></p>
<ul>
<li>
<p dir="auto">SEARCH  <strong><code>(?-s)(?&lt;=</code>String<code>)(.*\R)</code></strong></p>
</li>
<li>
<p dir="auto">REPLACE <strong><code>\1\r\n</code></strong></p>
</li>
</ul>
</li>
</ul>
<hr />
<p dir="auto">For instance, given this <em>INPUT</em> text :</p>
<pre><code class="language-diff">This is a
small example
of text
to test the
regexes
Hope this test will
be OK
</code></pre>
<p dir="auto">The <strong>first</strong> regex S/R would produce :</p>
<pre><code class="language-diff">This is a
small example
of text
to test the
regexes
Hope this test will
be OK

</code></pre>
<p dir="auto">The <strong>regex</strong> S/R :</p>
<ul>
<li>
<p dir="auto">SEARCH  <strong><code>(?-s)\A((?:.*\R){5})</code></strong></p>
</li>
<li>
<p dir="auto">REPLACE <strong><code>\1\r\n</code></strong></p>
</li>
</ul>
<p dir="auto">gives the following <em>OUTPUT</em> text :</p>
<pre><code class="language-diff">This is a
small example
of text
to test the
regexes

Hope this test will
be OK
</code></pre>
<p dir="auto">and, finally, the <strong>regex</strong> S/R :</p>
<ul>
<li>
<p dir="auto">SEARCH  <strong><code>(?-s)(?&lt;=test)(.*\R)</code></strong></p>
</li>
<li>
<p dir="auto">REPLACE <strong><code>\1\r\n</code></strong></p>
</li>
</ul>
<p dir="auto">would return :</p>
<pre><code class="language-diff">This is a
small example
of text
to test the

regexes
Hope this test will

be OK
</code></pre>
<p dir="auto">Best Regards,</p>
<p dir="auto">guy038</p>
<p dir="auto"><strong>P.S.</strong> :</p>
<p dir="auto">Of course, select the <strong><code>Regular expression</code></strong> search <strong>mode</strong> and <strong>tick</strong> the <strong><code>Wrap around</code></strong> option !</p>
]]></description><link>https://community.notepad-plus-plus.org/post/75590</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/75590</guid><dc:creator><![CDATA[guy038]]></dc:creator><pubDate>Wed, 30 Mar 2022 14:20:04 GMT</pubDate></item><item><title><![CDATA[Reply to ADD A LINE AT THE END on Wed, 30 Mar 2022 11:28:08 GMT]]></title><description><![CDATA[<p dir="auto">@memytim93</p>
<p dir="auto">Well you’d have to start by specifying how to identify these “certain lines already present”, i.e., what makes them special?  There has to be a pattern to it otherwise it can’t be done.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/75588</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/75588</guid><dc:creator><![CDATA[Alan Kilborn]]></dc:creator><pubDate>Wed, 30 Mar 2022 11:28:08 GMT</pubDate></item></channel></rss>