<?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[How to write a find ane replace experssion]]></title><description><![CDATA[<p dir="auto">I am trying to add back some formatting removed by a stupid program and I thought I could write a search and replace expression to make all the text in the rest of the file look like the first 2 lines where there would be a CR break after the first number in one huge line of text. Any ideas?</p>
<p dir="auto">17:30:19:&gt;&gt;&gt; WELCOME TO TEMPE, ARIZONA,<br />
17:30:22:THE WELLS FARGO ARENA, HOME OF<br />
17:30:24:THE SUN DEVILS OF ARIZONA STATE17:30:26:UNIVERSITY.17:30:27:ASU GETTING SET TO TAKE ON17:30:29:KENNESAW STATE.17:30:30:PART OF THE LEGENDS</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/11012/how-to-write-a-find-ane-replace-experssion</link><generator>RSS for Node</generator><lastBuildDate>Sun, 07 Jun 2026 16:24:35 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/11012.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 28 Dec 2015 00:50:28 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to write a find ane replace experssion on Mon, 28 Dec 2015 19:17:51 GMT]]></title><description><![CDATA[<p dir="auto">THANK YOU SO MUCH THAT WORKED GREAT!</p>
]]></description><link>https://community.notepad-plus-plus.org/post/12859</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/12859</guid><dc:creator><![CDATA[attathomeguy]]></dc:creator><pubDate>Mon, 28 Dec 2015 19:17:51 GMT</pubDate></item><item><title><![CDATA[Reply to How to write a find ane replace experssion on Mon, 28 Dec 2015 12:13:27 GMT]]></title><description><![CDATA[<p dir="auto">Hello <strong>attathomeguy</strong>,</p>
<p dir="auto">Easy enough, with <strong>regular</strong> expressions :-))</p>
<ul>
<li>
<p dir="auto">Open the <strong>Replace</strong> dialog ( <strong>CTRL + H</strong> )</p>
</li>
<li>
<p dir="auto">SEARCH <strong><code>.(?=\d\d:\d\d:\d\d:)</code></strong></p>
</li>
<li>
<p dir="auto">REPLACE <strong><code>$0\r\n</code></strong></p>
</li>
<li>
<p dir="auto">Check the <strong>Regular expression</strong> search mode</p>
</li>
<li>
<p dir="auto">Leave the <strong>. matches newline</strong> option <strong>UNchecked</strong></p>
</li>
<li>
<p dir="auto">if necessary, check the <strong>Wrap around</strong> option</p>
</li>
<li>
<p dir="auto">Click on the <strong>Replace All</strong> button</p>
</li>
</ul>
<p dir="auto">Et voilà !</p>
<p dir="auto"><strong>Notes</strong> :</p>
<ul>
<li>
<p dir="auto">The <strong>dot</strong> ( <strong><code>.</code></strong> ) represents any <strong>standard</strong> character ( different from <strong><code>\r</code></strong>, <strong><code>\n</code></strong> and <strong><code>\f</code></strong> )</p>
</li>
<li>
<p dir="auto">The syntax <strong><code>(?=\d\d:\d\d:\d\d:)</code></strong> is called a <strong>look-ahead</strong>, that looks, after the <strong>dot</strong>, for <strong>3</strong> sets of <strong>two digits</strong>, each of them followed with a <strong>colon</strong>. However, although this condition must be <strong>true</strong>, it’s <strong>NEVER</strong> part of the regex to be replaced. Therefore, the search regex is, only, the character <strong>just before</strong> the time syntax <strong>HH:MM:SS</strong>.</p>
</li>
<li>
<p dir="auto">The <strong><code>$0</code></strong>, in the <strong>replacement</strong> part, represents the <strong>entire</strong> regex matched, that is to say, the <strong>dot</strong>, which must be separated, from the <strong>HH:MM:SS</strong> form, with a <strong>line break</strong> ( <strong><code>\r\n</code></strong> ). If you use <strong>UNIX</strong> files, just change <strong><code>\r\n</code></strong> into <strong><code>\n</code></strong>.</p>
</li>
</ul>
<p dir="auto">So, the <strong>last</strong> line of your post :</p>
<pre><code>17:30:24:THE SUN DEVILS OF ARIZONA STATE17:30:26:UNIVERSITY.17:30:27:ASU GETTING SET TO TAKE ON17:30:29:KENNESAW STATE.17:30:30:PART OF THE LEGENDS
</code></pre>
<p dir="auto">will be replaced by the <strong>five</strong> lines below :</p>
<pre><code>17:30:24:THE SUN DEVILS OF ARIZONA STATE
17:30:26:UNIVERSITY.
17:30:27:ASU GETTING SET TO TAKE ON
17:30:29:KENNESAW STATE.
17:30:30:PART OF THE LEGENDS
</code></pre>
<p dir="auto">Best Regards,</p>
<p dir="auto">guy038</p>
<p dir="auto"><strong>P.S.</strong> :</p>
<p dir="auto">You’ll find <strong>good documentation</strong>, about the new <strong>Boost C++ Regex library</strong> ( similar to the <strong>PERL Regular Common Expressions</strong> ) used by <strong>Notepad++</strong>, since the <strong><code>6.0</code></strong> version, at the <strong>TWO</strong> addresses below :</p>
<p dir="auto"><a href="http://www.boost.org/doc/libs/1_48_0/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html" rel="nofollow ugc">http://www.boost.org/doc/libs/1_48_0/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html</a></p>
<p dir="auto"><a href="http://www.boost.org/doc/libs/1_48_0/libs/regex/doc/html/boost_regex/format/boost_format_syntax.html" rel="nofollow ugc">http://www.boost.org/doc/libs/1_48_0/libs/regex/doc/html/boost_regex/format/boost_format_syntax.html</a></p>
<ul>
<li>
<p dir="auto">The <strong>FIRST</strong> link explains the <strong>syntax</strong>, of regular expressions, in the <strong>SEARCH</strong> part</p>
</li>
<li>
<p dir="auto">The <strong>SECOND</strong> link explains the <strong>syntax</strong>, of regular expressions, in the <strong>REPLACEMENT</strong> part</p>
</li>
</ul>
]]></description><link>https://community.notepad-plus-plus.org/post/12847</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/12847</guid><dc:creator><![CDATA[guy038]]></dc:creator><pubDate>Mon, 28 Dec 2015 12:13:27 GMT</pubDate></item></channel></rss>