• Auto-complete user-defined language.

    1
    0 Votes
    1 Posts
    139 Views
    No one has replied
  • how to use middle mouse button to select text

    3
    0 Votes
    3 Posts
    877 Views
    Alan KilbornA

    @Brother-Creed said in how to use middle mouse button to select text:

    I am aware that we can already do this using alt + shift does this

    That’s for keyboard control of column block selection.
    With mouse (which you seem to want to use), just hold Alt while you click and drag with left mouse button.

    I want to use middle mouse instead as its easier to select and control.

    Alt+Lclickdrag is just as “easy”.

    i want to know if same thing is supported in notepad++

    No.

  • Split string with quotes to new line

    6
    1 Votes
    6 Posts
    12k Views
    J

    @guy038 @mkupper Thank you both for the additional information.

  • Create hyperlinks in Exsisting Table

    8
    0 Votes
    8 Posts
    481 Views
    guy038G

    Hello, @musocity, @coises and All,

    @musocity, I must admit that I shoud have remembered that an HTML link is always defined by a <a> tag, whose the href attribute specifies the link’s destination :-(

    But, in your first post, you textually said :

    So =POPSONG will link to
    httXX://mysongs.com/songs/=POPSONG.mp3

    Which is exactly what I did, in my second reply to you !!

    Now, if you had posted something like :

    I have a lot of <tr> blocks which, each, defines a song’s name, after the <td>/= chars

    For instance, I have this INPUT text :

    <tr> <td>=POPSONG</td> <td>R</td> <td>4/4</td> <td>ev8</td> <td>140</td> <td>Pop Piano Lite Solo Piano</td> <td>Ballad</td> <td>Pop 20</td> <td>2009/12</td> <td>RT 70</td> <td>2</td> <td>2</td> <td>Piano Ballad,Air,Celtic,Country Ballad,Worship</td> </tr>

    and I would like to get this OUTPUT :

    <tr> <td><a href="https://mysongs.com/songs/=POPSONG.mp3" title="">=POPSONG</a></td> <td>R</td> <td>4/4</td> <td>ev8</td> <td>140</td> <td>Pop Piano Lite Solo Piano</td> <td>Ballad</td> <td>Pop 20</td> <td>2009/12</td> <td>RT 70</td> <td>2</td> <td>2</td> <td>Piano Ballad,Air,Celtic,Country Ballad,Worship</td> </tr>

    I could have given you the exact answer, straight away !

    Now, regarding the replacement of some punctuation chars by their %encoded equivalent :

    I did not consider the -, ~, _ chars and the . dot if followed with mp3, which are non-reserved chars, as well as word chars

    I did not consider, either, the " double-quotes as well as the < and > chars, extensively used in HTML files

    Thus, the remaining characters to test are this list :

    !#$ %&'()*+,/:;=?@[]^`{|}

    Then, I chose this odd name’s song :

    !#$ Name%&of'()*+,/:;the=?@[]song^`{|}

    Followed by .mp3

    I found out a regex S/R which treats all these characters and replace them by their %encoded equivalent, in one go :

    - SEARCH (?:/=|>=|(?<!\A)\G)(?:(?s-i)(?!\.mp3|</a>).)*?\K(?:(\x20)|(!)|(#)|(\$)|(%)|(&)|(')|(\()|(\))|(\*)|(\+)|(,)|(/)|(:)|(;)|(=)|(\?)|(@)|([)|(\\)|(])|(\^)|(`)|(\{)|(\|)|(\})|(\.(?!mp3))) - REPLACE (?{1}%20)(?{2}%21)(?{3}%23)(?{4}%24)(?{5}%25)(?{6}%26)(?{7}%27)(?{8}%28)(?{9}%29)(?{10}%2A)(?{11}%2B)(?{12}%2C)(?{13}%2F)(?{14}%3A)(?{15}%3B)(?{16}%3D)(?{17}%3F)(?{18}%40)(?{19}%5B)(?{20}%5C)(?{21}%5D)(?{22}%5E)(?{23}%60)(?{24}%7B)(?{25}%7C)(?{26}%7D)(?{27}%2E)

    I took inspiration from this post :

    https://community.notepad-plus-plus.org/topic/22690/generic-regex-replacing-in-a-specific-zone-of-text

    To test this regex :

    First, copy the following text in a new tab <tr> <td><a href="https://mysongs.com/songs/=!#$ Name%&of'()*+,/:;the=?@[]song^`{|}.mp3" title="">=!#$ Name%&of'()*+,/:;the=?@[]song^`{|}</a></td> <td>R</td> <td>4/4</td> <td>ev8</td> <td>140</td> <td>Pop Piano Lite Solo Piano</td> <td>Ballad</td> <td>Pop 20</td> <td>2009/12</td> <td>RT 70</td> <td>2</td> <td>2</td> <td>Piano Ballad,Air,Celtic,Country Ballad,Worship</td> </tr> <tr> <td><a href="https://mysongs.com/songs/=!#$ Name%&of'()*+,/:;the=?@[]song^`{|}.mp3" title="">=!#$ Name%&of'()*+,/:;the=?@[]song^`{|}</a></td> <td>R</td> <td>4/4</td> <td>ev8</td> <td>140</td> <td>Pop Piano Lite Solo Piano</td> <td>Ballad</td> <td>Pop 20</td> <td>2009/12</td> <td>RT 70</td> <td>2</td> <td>2</td> <td>Piano Ballad,Air,Celtic,Country Ballad,Worship</td> </tr>

    Move to the very beginning of the file ( IMPORTANT )

    Open the Replace dialog ( Ctrl + H )

    Un-tick all box options

    - SEARCH (?:/=|>=|(?<!\A)\G)(?:(?s-i)(?!\.mp3|</a>).)*?\K(?:(\x20)|(!)|(#)|(\$)|(%)|(&)|(')|(\()|(\))|(\*)|(\+)|(,)|(/)|(:)|(;)|(=)|(\?)|(@)|([)|(\\)|(])|(\^)|(`)|(\{)|(\|)|(\})|(\.(?!mp3))) - REPLACE (?{1}%20)(?{2}%21)(?{3}%23)(?{4}%24)(?{5}%25)(?{6}%26)(?{7}%27)(?{8}%28)(?{9}%29)(?{10}%2A)(?{11}%2B)(?{12}%2C)(?{13}%2F)(?{14}%3A)(?{15}%3B)(?{16}%3D)(?{17}%3F)(?{18}%40)(?{19}%5B)(?{20}%5C)(?{21}%5D)(?{22}%5E)(?{23}%60)(?{24}%7B)(?{25}%7C)(?{26}%7D)(?{27}%2E)

    Select the Regular expression search mode

    Click once, on the Replace All button ( Do not use the Replace button )

    Important :

    Due to the presence of the \K syntax, in the search regex, you CANNOT use the Replace button and must trigger a global replacement !

    If you just want to know the different occurrences, which will be replaced later, simply use the Find Next or Find Previous button ( or F3 / Shift + F3 )

    And you should get this OUTPUT :

    <tr> <td><a href="https://mysongs.com/songs/=%21%23%24%20Name%25%26of%27%28%29%2A%2B%2C%2F%3A%3Bthe%3D%3F%40%5B%5C%5Dsong%5E%60%7B%7C%7D.mp3" title="">=%21%23%24%20Name%25%26of%27%28%29%2A%2B%2C%2F%3A%3Bthe%3D%3F%40%5B%5C%5Dsong%5E%60%7B%7C%7D</a></td> <td>R</td> <td>4/4</td> <td>ev8</td> <td>140</td> <td>Pop Piano Lite Solo Piano</td> <td>Ballad</td> <td>Pop 20</td> <td>2009/12</td> <td>RT 70</td> <td>2</td> <td>2</td> <td>Piano Ballad,Air,Celtic,Country Ballad,Worship</td> </tr> <tr> <td><a href="https://mysongs.com/songs/=%21%23%24%20Name%25%26of%27%28%29%2A%2B%2C%2F%3A%3Bthe%3D%3F%40%5B%5C%5Dsong%5E%60%7B%7C%7D.mp3" title="">=%21%23%24%20Name%25%26of%27%28%29%2A%2B%2C%2F%3A%3Bthe%3D%3F%40%5B%5C%5Dsong%5E%60%7B%7C%7D</a></td> <td>R</td> <td>4/4</td> <td>ev8</td> <td>140</td> <td>Pop Piano Lite Solo Piano</td> <td>Ballad</td> <td>Pop 20</td> <td>2009/12</td> <td>RT 70</td> <td>2</td> <td>2</td> <td>Piano Ballad,Air,Celtic,Country Ballad,Worship</td> </tr>

    Final clarification :

    Do not run this S/R twice ! Indeed, any % char of the encoded chars would be encoded as %25 again !

    Best Regards,

    guy038

  • How to refer named group in RegExp-replacement?

    5
    0 Votes
    5 Posts
    748 Views
    Mark OlsonM

    While we’re here, I’d like to talk about a related useful concept, namely how to reference a named pattern (but not the value captured earlier), which is extremely useful if you have some annoyingly long pattern that you need to match multiple times in the same regex.

    For example,
    (?'int'[-+]?\d+)\h*b+\h*(?&int)
    matches an integer with leading + or minus, some b characters, and then another integer (referenced with (?&int))

    I won’t expound too much on this topic because it’s also in the documentation, but I’ve definitely written many over-long regexes that could have been hugely simplified by this method.

  • Internet Search YouTube

    10
    1 Votes
    10 Posts
    765 Views
    PeterJonesP

    @Dawn said in Internet Search YouTube:

    By the way can I remove hotkeys I don’t use and that way setup the Run as a previous hotkey

    Yes. Settings > Shortcut Mapper

    Plus is there a way to select a line with a plugin hotkey so that I don’t need to use the triple click or use the hot key for selecting the front of the line and back of the line.

    I already suggested the method of recording a macro for the selection. That is the way to get that sequence as a single keystroke.

  • Find numbers greater than 101

    12
    0 Votes
    12 Posts
    3k Views
    Scott NielsonS

    OK, thanks @guy038

  • recording and running macro

    2
    0 Votes
    2 Posts
    155 Views
    Terry RT

    @zeta-orionis
    By reading the manual, available online here.

    Terry

  • 0 Votes
    3 Posts
    662 Views
    CoisesC

    A plugin I am developing can do this. It is called Columns++.

    After installing the plugin, start Notepad++, open your file and select the entire file. Then, from the Columns++ menu under the Plugins menu, select Search…. Fill in:

    Find what: num_1=\d+, num_2=\d+
    Replace with: num_1=(?=match), num_2=(?=98+2*match)

    and select Regular expression in the Search Mode box.

    Then click the Replace All button.

  • Collect duplicates in doc before sign

    2
    0 Votes
    2 Posts
    208 Views
    Mark OlsonM

    @Richie
    How many lines of data do you have? The optimal solution for this problem can vary a lot depending on how much data you have.

    Also, are all the entries with duplicate values before the # consecutive? For example, are all T-shirt entries grouped together, or are there non-T-Shirt entries between the first T-shirt entry and the last?

    Assuming the entries with duplicate values before # are grouped together, a reasonable solution (even for a large amount of data) would be as follows:

    Go to the find/replace form, Mark tab (Ctrl+M with default hotkeys) With Bookmark line selected and using Regular expression as search mode, enter (?-s)(^[^#\r\n]+)#.*\R(\1#.*$\R?)+ into the Find what box, and hit Mark all. Notes on this regular expression (general resources available here): (?-s) means that the . metacharacter won’t match newlines. (^[^#\r\n]+)# tries to match a sequence of characters that are not # or a line-end character at the start of a line followed by #, and then stores it as capture group 1. .*\R matches any number of non-newline characters, then a newline. (\1#.*$\R?)+ matches at least one line where the thing before # in the first line is followed immediately by # and then any number of characters before the end of the line ($) and then possibly a newline (\R? - the only thing there could be other than a newline here is the end of the file) You will see all the lines with a duplicate entry before # marked. Use Search->Bookmark->Remove Non-Bookmarked lines from the main menu. Now all the entries with no duplicate before the # will remain.

    Note that the Remove Non-Bookmarked lines operation can be rather slow if the number of lines to be removed is large (say, 10 thousand or more). If that’s a problem, you can use Copy Marked Text (the third button under the Mark all and Clear all marks buttons in the Mark form) instead to copy the text that you marked in step 2, then paste it into another buffer (or select the entire original file and paste over it). You’d have to do some simple regex-based postprocessing of the result after that, but I’ll leave that as an exercise for you.

    If the entries with duplicate values are not grouped together, you will need to sort the entries by the value before the #, and then follow the steps above. This sorting is difficult to achieve without a custom script, but fortunately I and fellow forum regular AlanKilborn have already written such a script.

  • Print error 0x80040003

    11
    0 Votes
    11 Posts
    3k Views
    xomxX

    @mkupper
    It probably works so that when N++ calls the printing WINAPI, that system call always checks for the above RegKey first and then adapts the appearance of the Print-dlg.

    Because I could not reproduce the problem myself, I can only guess what a real problem is. Because the printing basically works (with admin-rights), perhaps the MS will be able to fix it in a later build.

  • Dutch as install language, instead of English

    Locked
    2
    0 Votes
    2 Posts
    1k Views
    donhoD

    @Rich-Hisgen
    Does this problem persist for the latest version (v8.5.7)?

  • How to change word and numerate this document!!

    5
    0 Votes
    5 Posts
    333 Views
    Claudio RaphaelC

    @Coises

    Sir, you are awesome!! Thank u very much.

    Claudio Raphael

  • Assistance Required: Recovery of Corrupted Notepad++ Tabs

    3
    0 Votes
    3 Posts
    275 Views
    PeterJonesP

    @M-Socin said in Assistance Required: Recovery of Corrupted Notepad++ Tabs:

    I have had 25 tabs open in Notepad++ since around 2019, which, due to the program’s auto-reopen feature, I never found the need to save.

    You’ve had the same unsaved files for 4+ years?! First, you’ve been lucky to date. Second, I highly recommend changing your data practices – see our FAQ section on the Backup / AutoSave, to figure out how to set things up to be safer so that you’re less likely to lose your data.

    That FAQ also has some suggestions for things you can try to recover lost data – including describing the directories that things might be in, depending on your settings; but Notepad++ doesn’t have built-in file recovery, so if the file is corrupt or lost, there is nothing we or Notepad++ can do for you; the FAQ mentions that you might have success using external recovery tools, but we don’t guarantee that will work nor are we experts at their use.

    .'¨}ö& 3iŮa]ž<Á«PŮ×vo ...

    That looks like a binary file. If it didn’t used to be a binary file, then one of a few things happened:

    A Windows crash corrupted the files. You were infected with a virus, and the virus has corrupted your files.

    Since you didn’t ever actively save or back up your important data, that data is likely lost in either case, but recovery software (as mentioned at in the FAQ) might be able to find some of your files (though it might be an older version). Good luck.

    For the future, I highly recommend following data best-practices, as described in the FAQ, and taking an active role in making sure you don’t lose important data in the future (whether you edit that data in Notepad++ or any other tool; no single tool can guarantee 100% that you won’t lose data due to circumstances outside their control).

  • Auto completeion is not working

    3
    0 Votes
    3 Posts
    195 Views
    PeterJonesP

    @Jayden-Gird said in Auto completeion is not working:

    It does nothing.

    Do you have other text in your file yet? If not, then the “word completion” half of the auto-completion feature will not do anything, because “word completion” requires other words to be in your file.

    Do you have a Language set in the Language menu (like HTML or C++ or anything else from that menu)? If not, then the “function completion” half of that feature will not do anything, because “function completion” requires an active programming language to be set.

  • Deploying Notepad ++ from SCCM console

    1
    0 Votes
    1 Posts
    305 Views
    No one has replied
  • installing notepad++ portable zip

    2
    0 Votes
    2 Posts
    190 Views
    Terry RT

    @zeta-orionis
    Try the online manual here.

    Terry

  • Searching random duplicate numbers/values in Notepad++

    15
    0 Votes
    15 Posts
    1k Views
    Alan KilbornA

    @Mark-Olson said in Searching random duplicate numbers/values in Notepad++:

    I don’t particularly appreciate people (cf. AlanKilborn) nitpicking my solution, which was perfectly adequate for this problem.

    Too bad? We try to keep things “on track” here. If something devolves into “I’ll write what is effectively not a Notepad++ solution” here, it shouldn’t be here.

  • How to silent install NPP 7.7 ? (MDT installation)

    4
    0 Votes
    4 Posts
    10k Views
    LeroyDemarcusL

    Have you tried googling it?

  • Removing Text Before and After dialogue.

    5
    0 Votes
    5 Posts
    805 Views
    Borderless MediaB

    I want to Thank you guys for this. Yesterday I tried Peter’s code first and it worked but there were still some things left behind. Inevitably i found a wayto cancel them out so great work either way.

    Terry for some reason My Notepad++ freezes when i used your method to replace all.

    Guy038, yours worked perfectly. It got rid of everything and also spaced out the lines. I intended to put them into a word doc and realized that word automatically spaces out lines so it seems I put you guys through a bit more work than needed but those codes got the job done. I won’t be needing further help on this i believe.

    Thanks again and warm regards