• Changing language association of file extension

    6
    0 Votes
    6 Posts
    709 Views
    jofe95J

    @PeterJones
    OK, after reopening the *.inc file, it seems to work now. Thank you!

  • RegEx help - find & replace specific word at the end of a line

    4
    0 Votes
    4 Posts
    703 Views
    JustinJudoJ

    @Alan-Kilborn said in RegEx help - find & replace specific word at the end of a line:

    Find: (?-s)^(.+?), The$
    Replace: The ${1}

    That’s exactly it! Thank you Alan.

  • Macro to Replace Whole Word

    7
    0 Votes
    7 Posts
    308 Views
    Mark OlsonM

    @MaximillianM
    Glad it’s working now! Very strange that you were having this problem.

  • Sort Lines Lexicographically did not work

    61
    1 Votes
    61 Posts
    21k Views
    CoisesC

    @Cooeeeee said in Sort Lines Lexicographically did not work:

    I’ve been using Notepad++ for years. My most used feature is Sort Lexicographically to sort a column mode selection (i.e. I essentially have a table of data). For example, I’ll use Alt+Shift and maybe select columns 27-30 across all lines, then do a lexicographical sort on that.

    Today I encountered a list that wasn’t sorting correctly. I’ve not had this problem before. My lines had some tabs prior to the columns I was trying to sort. Reading through this thread gave me the idea to try the “TAB to space” conversion. My listed would sort correctly after making that adjustment. Somehow the tabs were breaking it. I figured I’ll leave this tip here in case it can help anyone else.

    Indeed, sorting by column does not work if there are tabs before the columns. No doubt for efficiency, the column sort in Notepad++ determines a single pair of starting and ending character positions to apply to all lines, rather than independently extracting the selected text on every line; tabs are treated as single characters, no matter how wide they are on the display.

    If you’re interested in a pre-release version of a plugin, Columns++ includes a sort function which works as expected when there are tabs in the document.

  • search replace wildcards

    2
    0 Votes
    2 Posts
    141 Views
    Alan KilbornA

    @R-Harms

    Hmmm…wildcards…are you sure you read the manual?

  • Notepad++ rolling back to older version at every restart

    2
    0 Votes
    2 Posts
    408 Views
    PeterJonesP

    @Francesco-Saltalamacchia ,

    Any idea why?

    Two ideas:

    Your institution installed in location X, but you installed to location Y, so when you reboot and start Notepad++, you are running the location-X version rather than your location-Y version. To prove this: after doing your installation, look at ?-menu Debug Info and note the path after your reboot and running Notepad++, look at the same info. Are they the same or different? Your institution force-installs the v7.9.1 after you installed “the latest” (whichever version that is.) the same substeps from #1.1-2 would work here for helping to see if the version is changing but running from same location.
  • Saving Compare output to a file.

    3
    0 Votes
    3 Posts
    18k Views
    Daniel HolzmannD

    Apologies for being very late to this party, but I was exactly looking for an answer to this question.
    I wanted to share my workaround for not being able to export comparison results in Notepad++. I used the compare function in MS Word instead, which achieved this.

  • Translate document?

    2
    0 Votes
    2 Posts
    382 Views
    PeterJonesP

    @Ivikdor ,

    The Translate plugin is a 32-bit-only plugin that hasn’t been updated since 2015. If you have the 32-bit Notepad++, it will show up in your Plugins Admin; since you say you don’t see it, I am assuming you have the 64-bit Notepad++ instead.

    But since the plugin hasn’t been updated since 2015, even if you were to switch to 32-bit Notepad++ (which I don’t think is really a good idea), it is highly likely that the plugin would no longer be compatible, because Notepad++'s plugin interface and underlying interactions have changed significantly in the last eight years, and the chances are that some or all of the features as implemented are not compatible with modern Notepad++.

  • Using the PythonScript plugin to automate N++

    53
    0 Votes
    53 Posts
    5k Views
    Alan KilbornA

    @TBugReporter said in Using the PythonScript plugin to automate N++:

    I’m not sure whether you’re way overthinking this, or I’ve way underestimated the possibilities

    I don’t know… You posed a fairly reasonable desire, and I put some reality onto some potential problems with getting to where you wanted to go.

    Better to expose the “real world” of it, if it is known, before trying to solve the problem…, which we are now NOT going to do. :-)

  • shortcuts.xml in notepad++

    8
    0 Votes
    8 Posts
    1k Views
    TBugReporterT

    @PeterJones said in shortcuts.xml in notepad++:

    Whine at @Alan-Kilborn because he keeps teasing his new script without making it public Kindly remind @Alan-Kilborn that he hasn’t published his script yet

    @Lycan-Thrope said in shortcuts.xml in notepad++:

    In other words, you’re trying vainly to fool-proof it.

    Could it be that there’s another person on here who’s guilty of letting the “perfect” be the enemy of the “good”? Shocking! 😯

    @Alan-Kilborn said in shortcuts.xml in notepad++:

    No, just trying to find the time, amid other projects, to finish it.

    Send me a copy - I’ll finish it for you (but it’ll be 10Mb when I’m done)! 😁

  • Difference in regular expressions between Search and Function List?

    4
    0 Votes
    4 Posts
    414 Views
    RobertER

    @PeterJones Just wanted to let you know that after I closed down Notepad++ and reopened it, now the Function List works perfectly in all files. Thanks again.

  • my css code for color not working and error message when run

    5
    0 Votes
    5 Posts
    2k Views
    Lycan ThropeL

    @Michelle-Vedros ,
    In addition to what @PeterJones has pointed out to you, your code doesn’t work, even when you use the Notepad++ menu’s View->View Current File in->(browser choice) to view it. That’s because your code is in error. You need to consult an HTML/CSS/Javascript site, like the W3C Schools courses to better learn what you did wrong. I tried your code that way and in both Chrome and Firefox and it did exactly what you coded it to do. It just didn’t do what you wanted it to do, and that’s why I’ve just given you the link you need to follow to learn how to do it right.

  • Need Regex to Delete HTML attribute

    6
    1 Votes
    6 Posts
    839 Views
    Mark OlsonM

    Lycan-Thrope’s response is adequate for your needs as stated, and has the added bonus of being (probably) fast to execute and easy to understand.

    But if you’re curious, here’s an alternative that minimizes side-effects:
    replace (<a[^>]*?)\s*title\s*=\s*".*?"([^>]*?>) with \1\2.

    Before:

    <a href="fjoenr" title="oenrwn"><i title="eorn">eron</i></a> <a title = "eroeno">foenfeonf title="eoeno"</a> <p>title="Ereoneorn"</p> <a href="eoenoen"></a>title="eoenon" <a title="eoenon" href="eoenroenro">""</a>

    After:

    <a href="fjoenr"><i title="eorn">eron</i></a> <a>foenfeonf title="eoeno"</a> <p>title="Ereoneorn"</p> <a href="eoenoen"></a>title="eoenon" <a href="eoenroenro">""</a>
  • Invisible the cursor/Caret in V8.4.8

    2
    0 Votes
    2 Posts
    141 Views
    PeterJonesP

    @Sáfián-Lajos

    Cannot reproduce.

    Light mode, Deep Black theme: cursor not invisible – I can see it in this screenshot between not and invisible:
    96867134-0fcd-41a2-91b2-6b18ac0fb9e5-image.png

    Dark Mode, Deep Black theme: cursor not invisible – I can see it in this screenshot between n and v in invisible:
    8eb59743-661a-472d-a334-59bbe2e8c2e1-image.png

    Please note that theme is irrelevant: the colors of the Find dialog are set by the Light Mode / Dark Mode, not by the Theme.

  • How to combine two text documents to fill in blank lines

    10
    0 Votes
    10 Posts
    404 Views
    Alan KilbornA

    In my previous posting, I used the regular expression \d\d a few times. This was because that “fit” the test data I was working with (had 9 < #lines < 100).

    If OP has a different number of lines in his real world scenario, which is likely, probably a better expression is \d+.

    Again, when help is provided here, it may not be an exact fit for a situation that is not explicitly mentioned in the questioner’s problem statement, and may need to be adjusted, but the general solution technique should be solid.

  • Add row-gap property in langs.xml/CSS language

    Locked
    1
    0 Votes
    1 Posts
    166 Views
    No one has replied
  • Is it possible to delete plugins from command line

    7
    0 Votes
    7 Posts
    535 Views
    moltraM

    @PeterJones ok thanks, I uninstalled it using the companies software center and it is still not starting. I am going to have to get IT support to help delete the Notepad++ folder and then I can reinstall.

  • Help needed urgently.

    8
    0 Votes
    8 Posts
    523 Views
    guy038G

    Hello, @somethingmad, @peterjones and All,

    @somethingMad, here is an other alternative to the @peterjones’s solution. So, given this INPUT text :

    lori.figaro@gmail.com|5.69272238158E11|4547490.0|#11811391_PRP|LORI|FIGARO|75.85|0.0|75.85|0.00|75.85|2622 AVALON FOREST CT||SPRING|Shipping|United States|US|LORI|FIGARO|LORI FIGARO|7132049425|Texas|TX|77386-2972|30.14205889999999|-95.40070209999999||2018-09-15 19:15:52.000|1537064180000|2018-09-01 stcstout@ruraltel.net|5.6932954939E11|4547618.0|#11811461|Tyna| Stoutimore |31.9|0.0|31.9|0.00|39.85|11 SW 2ND ST||PHILLIPSBURG|Shipping|United States|US|Tyna| Stoutimore |Tyna Stoutimore |7855432781|Kansas|KS|67661-2609|39.7476562|-99.32758539999999||2018-09-15 22:53:47.000|1537077256000|2018-09-01 annijchaz@msn.com|5.69279643726E11|4547508.0|#11811400_PRP|Annette|Chavez|128.65|0.0|128.65|0.00|163.65|5812 TRAIL CT NW||ALBUQUERQUE|Shipping|United States|US|Annette|Chavez|Annette Chavez|5053071755|New Mexico|NM|87107|35.1414399|-106.6457214||2018-09-15 19:40:47.000|1537065705000|2018-09-01

    with the regex S/R below :

    (?xi) ^ # SEARCH regex in 31 lines ( [\w.@]* ) \| # Field 01 ( [\dE.]* ) \| # Field 02 ( [\d.]* ) \| # Field 03 ( \# \w* ) \| # Field 04 ( [\w ]* ) \| # Field 05 ( [\w ]* ) \| # Field 06 ( [\d.]* ) \| # Field 07 ( [\d.]* ) \| # Field 08 ( [\d.]* ) \| # Field 09 ( [\d.]* ) \| # Field 10 ( [\d.]* ) \| # Field 11 ( [\w ]* ) \| # Field 12 ( [\w.: -]* ) \| # Field 13 EMPTY ( \w* ) \| # Field 14 ( \w* ) \| # Field 15 ( [\w ]* ) \| # Field 16 ( \w* ) \| # Field 17 ( [\w ]* ) \| # Field 18 ( [\w ]* ) \| # Field 19 ( [\w ]* ) \| # Field 20 ( \d* ) \| # Field 21 ( [\w ]* ) \| # Field 22 ( \w* ) \| # Field 23 ( [\d-]* ) \| # Field 24 ( [\d.]* ) \| # Field 25 ( [\d.-]* ) \| # Field 26 ( [\w.: -]* ) \| # Field 27 EMPTY ( [\d.: -]* ) \| # Field 28 ( \d+ ) \| # Field 29 ( [\d-]* ) $ # Field 30

    REPLACE $1|$5|$6|$12|$14|$16|$21|$23|$29

    We get this OUTPUT text :

    lori.figaro@gmail.com|LORI|FIGARO|2622 AVALON FOREST CT|SPRING|United States|7132049425|TX|1537064180000 stcstout@ruraltel.net|Tyna| Stoutimore |11 SW 2ND ST|PHILLIPSBURG|United States|7855432781|KS|1537077256000 annijchaz@msn.com|Annette|Chavez|5812 TRAIL CT NW|ALBUQUERQUE|United States|5053071755|NM|1537065705000

    Practically :

    Close the Find/Replace/Mark dialog if already opened

    Select all the search regex, between (?x) and Field 30 included

    Open the Replace dialog ( Ctrl + H )

    => The Find what : zone is immediately populated

    Select all the replacement regex and paste it in the Replace with : zone

    Uncheck all box options

    Check the Wrap around option

    Select the Regular expression search mode

    Click once on the Replace All button

    Of course, as I’m French, just verify if the appropriate columns are written after the global replacement !! Anyway, it shouldn’t be difficult to select the right columns, with the given search regex ;-)

    Best Regards,

    guy038

  • Is there any way to convert code points to unicode

    14
    0 Votes
    14 Posts
    2k Views
    Alan KilbornA

    @dinkumoil said:

    You could create an HTML file that includes your code points as HTML entity numbers

    …and…

    @rdipardo said:

    you can encode the text as numeric entities, then convert them right in Notepad++ with the HTML Tag plugin

    …and that’s all fine, but the OP ( @User-000 ) had a title on this posting of “Is there any way to convert code points to unicode”, so I found it curious that no example was provided that actually had some fun and uses any “fancy” unicode characters. (Of course, OP didn’t do this in his sample data, either…).

    I didn’t try with the HTML Tag plugin, but I did try the “HTML file” approach with some “fancy” character data:

    <body> <p> &#72&#101&#108&#108&#111&#32&#87&#111&#114&#108&#100&#33&#x25BC&#x1F499 </p> </body>

    and indeed it worked just fine to show the fancy-ness for characters U+25BC and U+1F499; here shown in Chrome:

    547dfa37-ee07-4847-ada1-da6b98332cd1-image.png

  • Search and extract results between two strings in multiple files

    6
    0 Votes
    6 Posts
    3k Views
    Amit PandeyA

    Hello @guy038 ,

    My bad, i misinterpreted your reply and went into a different direction.
    (also had to upgrade my NPP (upgraded to v8.4.9) to reflect ‘Copy Marked text’ option".

    I have now achieved what is required.

    Here are the steps which i followed

    Search for Regex String ‘PROCEDURE INIT-RECORD|ASSIGN|END PROCEDURE’ across the files Copied the search result in a new window Applied regex search string provided by you in the earlier reply’ and followed the provided steps All the target keywords within the target procedure were marked Used ‘Copy Marked Text’ option and got my results

    Thanks a lot for your help.