<?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 Question]]></title><description><![CDATA[<p dir="auto">Fellow Notepad++ Users,</p>
<p dir="auto">Could you please help me with the following search-and-replace problem I am having?</p>
<p dir="auto">I have a massive PS1 code database which looks like this:</p>
<p dir="auto">“Darius Gaiden (Japan) {SLPS-00574}”<br />
:SLPS-00574<br />
#P1 Infinite Lives<br />
$801051CC 0009<br />
#P2 Infinite Lives<br />
$80105244 0009<br />
#P1 Infinite Bombs<br />
$801051BE 0003<br />
#P2 Infinite Bombs<br />
$80105236 0003<br />
#P1 Invincibility<br />
$801051A8 007F<br />
#P2 Invincibility<br />
$80105220 007F</p>
<p dir="auto">“Gran Turismo (Japan, Asia) {SCPS-10045}”<br />
:SCPS-10045<br />
#Gran Turismo mode/Infinite Money<br />
$8008DD06 00FF<br />
#Gran Turismo mode/Have B License<br />
$90090854 03030303<br />
$90090858 03030303<br />
#Gran Turismo mode/Have A License<br />
$9009085C 03030303<br />
$90090860 03030303<br />
#Gran Turismo mode/Have A International License<br />
$90090864 03030303<br />
$90090868 03030303<br />
#High Racing Points<br />
$9008DD04 05F5E100</p>
<p dir="auto">“Gran Turismo 2 (Disc 2) (Gran Turismo) (Japan) Rev 1 {SCPS-91327}”<br />
;:SCPS-91327<br />
;This game currently has no cheats</p>
<p dir="auto">“Gran Turismo 2 (Japan) (Test Drive Disc) {PAPX-90054}”<br />
;:PAPX-90054<br />
;This game currently has no cheats</p>
<p dir="auto">“Gran Turismo 2 (Un CD Bonus) (France) {SCED-02904}”<br />
;:SCED-02904<br />
;This game currently has no cheats</p>
<p dir="auto">“Grand Theft Auto (Europe) (EDC Platinum, Collector’s Edition) {SLES-00032}”<br />
:SLES-00032<br />
#Infinite Weapons, Ammo, 99 Lives &amp; Coordinates<br />
$80025F90 00FF<br />
#Open All Cities<br />
$80025F2C 0001<br />
$80025F30 0001<br />
$80025F34 0001<br />
$80025F38 0001<br />
$80025F3C 0001<br />
#Maximum Armour This code gives you maximum armour but you must pick up the armour first<br />
$800A92F0 7FFF<br />
#No Police Activity<br />
$8002B488 0000<br />
#Infinite Lives<br />
$8002B5F2 0063<br />
#Infinite Pistol And Ammo<br />
$8002B5FC FF00</p>
<p dir="auto">“Grand Theft Auto (Europe) {SLES-00032}”<br />
:SLES-00032<br />
#Infinite Weapons, Ammo, 99 Lives &amp; Coordinates<br />
$80025F90 00FF<br />
#Open All Cities<br />
$80025F2C 0001<br />
$80025F30 0001<br />
$80025F34 0001<br />
$80025F38 0001<br />
$80025F3C 0001</p>
<p dir="auto">I would like it to look like this:</p>
<p dir="auto">“Darius Gaiden (Japan) {SLPS-00574}”<br />
:SLPS-00574<br />
#P1 Infinite Lives<br />
$801051CC 0009<br />
#P2 Infinite Lives<br />
$80105244 0009<br />
#P1 Infinite Bombs<br />
$801051BE 0003<br />
#P2 Infinite Bombs<br />
$80105236 0003<br />
#P1 Invincibility<br />
$801051A8 007F<br />
#P2 Invincibility<br />
$80105220 007F</p>
<p dir="auto">“Gran Turismo (Japan, Asia) {SCPS-10045}”<br />
:SCPS-10045<br />
#Gran Turismo mode/Infinite Money<br />
$8008DD06 00FF<br />
#Gran Turismo mode/Have B License<br />
$90090854 03030303<br />
$90090858 03030303<br />
#Gran Turismo mode/Have A License<br />
$9009085C 03030303<br />
$90090860 03030303<br />
#Gran Turismo mode/Have A International License<br />
$90090864 03030303<br />
$90090868 03030303<br />
#High Racing Points<br />
$9008DD04 05F5E100</p>
<p dir="auto">“Grand Theft Auto (Europe) (EDC Platinum, Collector’s Edition) {SLES-00032}”<br />
:SLES-00032<br />
#Infinite Weapons, Ammo, 99 Lives &amp; Coordinates<br />
$80025F90 00FF<br />
#Open All Cities<br />
$80025F2C 0001<br />
$80025F30 0001<br />
$80025F34 0001<br />
$80025F38 0001<br />
$80025F3C 0001<br />
#Maximum Armour This code gives you maximum armour but you must pick up the armour first<br />
$800A92F0 7FFF<br />
#No Police Activity<br />
$8002B488 0000<br />
#Infinite Lives<br />
$8002B5F2 0063<br />
#Infinite Pistol And Ammo<br />
$8002B5FC FF00</p>
<p dir="auto">“Grand Theft Auto (Europe) {SLES-00032}”<br />
:SLES-00032<br />
#Infinite Weapons, Ammo, 99 Lives &amp; Coordinates<br />
$80025F90 00FF<br />
#Open All Cities<br />
$80025F2C 0001<br />
$80025F30 0001<br />
$80025F34 0001<br />
$80025F38 0001<br />
$80025F3C 0001</p>
<p dir="auto">I want to delete every game from the list which doesn’t have any codes. (Doesn’t have any “$” or “#” symbol)</p>
<p dir="auto">So it would be something like:<br />
Delete “Game” and everything before the “Next game” if there is no “$” symbol at the beginning of any line before “Next game”</p>
<p dir="auto">Regards<br />
Pap</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/23891/search-replace-question</link><generator>RSS for Node</generator><lastBuildDate>Tue, 21 Jul 2026 13:30:11 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/23891.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 14 Dec 2022 16:38:03 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Search&#x2F;Replace Question on Wed, 14 Dec 2022 22:24:58 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/papryk-g" aria-label="Profile: Papryk-G">@<bdi>Papryk-G</bdi></a> said in <a href="/post/82473">Search/Replace Question</a>:</p>
<blockquote>
<p dir="auto">that works except sometimes I’m left with empty titles</p>
</blockquote>
<p dir="auto">None of your examples showed titles with no lines after the title, sorry.</p>
<ul>
<li>FIND = <code>(?-s)^".*?"(\R[^#\$].*?$)*?(\R\R|\Z)</code></li>
</ul>
]]></description><link>https://community.notepad-plus-plus.org/post/82474</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/82474</guid><dc:creator><![CDATA[PeterJones]]></dc:creator><pubDate>Wed, 14 Dec 2022 22:24:58 GMT</pubDate></item><item><title><![CDATA[Reply to Search&#x2F;Replace Question on Wed, 14 Dec 2022 23:48:39 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/peterjones" aria-label="Profile: PeterJones">@<bdi>PeterJones</bdi></a> Thank you, that works except sometimes I’m left with empty titles like this:</p>
<pre><code>"Spyro the Dragon (Japan) (Shokai Genteiban) {SCPS-10083}"
:SCPS-10083
#Infinite Timer
$8007F3D0 0600
$8007F4A4 0600
#Invincibility
$800829FC 0003
#Hundred percent
$8007F2BA 00C8
$8008101C 0064
#Infinnite Credit
$8007F3C0 0004

"Spyro the Dragon (Japan) Demo {PAPX-90078}"

"Spyro the Dragon (Japan) {SCPS-10085}"
:SCPS-10085
#Infinite Timer
$8007F3D0 0600
$8007F4A4 0600
#Invincibility
$800829FC 0003
#Hundred percent
$8007F2BA 00C8
$8008101C 0064
#Infinnite Credit
$8007F3C0 0004

"Spyro the Dragon Speciale (France) Demo {SCED-01637}"
"Spyro x Sparx: Tondemo Tours (Japan) Demo {PCPX-96191}"

"Spyro x Sparx: Tondemo Tours (Japan) {SCPS-10128}"
:SCPS-10128
#Infinite Health
$8006CE04 0003
#Score Gem Max
$800697F0 FFFF
#Infinite Lives
$80069850 0004
#Bonus Screen Infinite time
$8006C464 070A
#And (rising gradually to jump) airborne
$8006CC44 05FF
</code></pre>
]]></description><link>https://community.notepad-plus-plus.org/post/82473</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/82473</guid><dc:creator><![CDATA[Papryk G]]></dc:creator><pubDate>Wed, 14 Dec 2022 23:48:39 GMT</pubDate></item><item><title><![CDATA[Reply to Search&#x2F;Replace Question on Wed, 14 Dec 2022 16:56:27 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/papryk-g" aria-label="Profile: Papryk-G">@<bdi>Papryk-G</bdi></a> ,</p>
<p dir="auto">In the future, please use the <code>&lt;/&gt;</code> button while your example text is selected, so that it marks it as code/literal text (that way, your real quotes won’t become smart quotes)</p>
<p dir="auto">This search regex will match any single “game” that does not have any line starting with <code>#</code> or <code>$</code><br />
FIND = <code>(?-s)^".*?"(\R[^#\$].*?$)+?(\R\R|\Z)</code></p>
<p dir="auto">You can then replace it with the empty string to delete it.</p>
<p dir="auto">Search Mode must be regular expression.</p>
<p dir="auto">(This assumes there is no indentation, and that it’s real ASCII quotes not “smart quotes”, and no blank space between the close-quote and the newline sequence, and that a game ends with an empty line or with the end-of-file)</p>
<p dir="auto">-—</p>
<h3>Useful References</h3>
<ul>
<li><a href="https://community.notepad-plus-plus.org/topic/21965/please-read-before-posting">Please Read Before Posting</a></li>
<li><a href="https://community.notepad-plus-plus.org/topic/22022/template-for-search-replace-questions">Template for Search/Replace Questions</a></li>
<li><a href="https://community.notepad-plus-plus.org/topic/21925/faq-desk-formatting-forum-posts">Formatting Forum Posts</a></li>
<li><a href="https://community.notepad-plus-plus.org/topic/15765/faq-desk-where-to-find-regular-expressions-regex-documentation">FAQ: Where to find regular expressions (regex) documentation</a></li>
<li><a href="https://npp-user-manual.org/docs/searching/#regular-expressions" rel="nofollow ugc">Notepad++ Online User Manual: Searching/Regex</a></li>
</ul>
]]></description><link>https://community.notepad-plus-plus.org/post/82467</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/82467</guid><dc:creator><![CDATA[PeterJones]]></dc:creator><pubDate>Wed, 14 Dec 2022 16:56:27 GMT</pubDate></item></channel></rss>