• 0 Votes
    4 Posts
    456 Views
    PeterJonesP

    @Ivan-Lewis-Coker,

    The other respondants are helping with your actual issue, but I thought I’d reply to:

    I didn’t see a Search option to look

    The toolbar of the forum has a magnifying glass, which indicates “search”, just like magnifying glasses do in many other tools (including Notepad++)

    1bafccac-2b9e-4c20-9aba-ee207b30a577-image.png

    Click on the search icon, then type your search text. It’s not the world’s best search, but it will work.

    And I am also assuming you actually know about Google’s advanced search syntax (which you can enter in a normal Google search bar, not just from their advanced search page). This syntax allows you to search by site, so site:community.notepad-plus-plus.org search terms here will restrict your google search to our Community.

  • Problem launching NPP with file from IDE

    17
    0 Votes
    17 Posts
    813 Views
    Lycan ThropeL

    @PeterJones ,
    Thanks for helping me find this out. This is strange, because when we put filepath/filename in the code, we do surround them with quotes for the reasons you point out.

    Why the IDE would not pass a filepath/filename parameter without quotes around it is strange, unless the way the IDE is designed, it does it internally, as witnessed by those two different ways it displays depending on if there is spaces in it. In other words, the IDE interpreter sees the spaces, and then puts quotes around it for itself. This makes sense, but making it more difficult for us to use external editors without passing it that way is definitely perplexing. Just as an FYI, the dBASE Plus editor is based on the SciTE editor that they changed to in the dBASE Plus 9 version, so it does share at least a little bit of familial genes with NPP, namely the Scintilla library. :-)

  • Save as type "All types" as default?

    4
    0 Votes
    4 Posts
    2k Views
    mpheathM

    @Kjell-Rilbe From a casual observation.

    Important to note: The Save As dialog has a checkbox named Append extension.

    If Append extension checkbox is checked, then the filter combobox named Save as type will auto-select the filetype to match the existing file type or language. So if Save as type is Normal text file (*.txt), then it is known for Notepad++ to append .txt to the File name in edit control on save.

    If Append extension checkbox is unchecked, then the filter combobox named Save as type will auto-select All types (*.*) as the state of appending a file extension is undetermined so that the user needs to type into the whole file name including file extension to save as a file type.

    Perhaps for the 10+ years mentioned the checkbox Append extension has been unchecked for your Notepad++ configuration. One day it changed and the usual routine afterwards was disrupted.

    Just viewed config.xml with changing the checkbox state and closing Notepad++. The state is remembered for the next Notepad++ instance:

    <GUIConfig name="MISC" ... saveDlgExtFilterToAllTypes="yes" ... />

    The value can toggle with value yes and no. There should be no need to change this value manually if a Gui method is available … ( Append extension ).

    The Preferences dialog shows no mention that I could see to influence the state of the Save as type combobox and so I consider the Append extension is the main point of change.

    The suggested fix for you is to uncheck Append extension on the next Save As event.

  • 0 Votes
    2 Posts
    912 Views
    PeterJonesP

    @Лі-Лантер ,

    How do I convert(?) the text on notepad to chrome?

    This forum is about Notepad++. Calling it “notepad” makes it look like you’re talking about the microsoft windows built-in editor “notepad”. If you are really talking about Notepad++, please do not forget the ++, as it is part of the name. Using the right name helps us make sure you’re actually talking about Notepad++ and are asking in the right place.

    I need to convert the stuff I wrote in notepad to a chrome version.

    Notepad++ is a text editor. Chrome is a web viewer. If you wrote HTML using Notepad++, you do not need to “convert” anything. You open the file with Chrome to render and view the page.

    (The video I watched has a different version of notepad)

    We have no clue what video you watched, or what “version of Notepad++” either you or “the video” is using.

    When I press the “run” button(I’m not working on an english ver of notepad, not sure if I’m calling everything correctly), I press start and get a small window that says “enter the program launch options” with an empty typing window.

    In Notepad++'s default English translation, there is a Run menu with a Run… action,
    7c81f913-6864-4d91-b89a-772f1bd079a3-image.png
    which opens a dialog box that looks like:
    355275dd-66ae-4fe9-8d73-f23e61eccd40-image.png

    I type in “chrome” and it just takes me to the main chrome page.

    Of course it does. The Run… dialog is very similar to typing a command from cmd.exe or a powershell window, or from the windows Win+R run-a-command dialog
    ec4563ab-e144-4f3e-a824-2cc46940f872-image.png

    If you don’t give the chrome command any command-line argument to tell it what file to launch, it will just open the Chrome application without directing it to open a specific file.

    But based on everything you told me, my guesses are:

    The video you watched was using a really old version of Notepad++ (older than v7.6.3 from 2019) The video you watched showed using Run > Launch In Chrome, which does not exist in your newer copy of Notepad++ Those commands have been replaced by View > View Current File in > Chrome and similar:
    694306bd-c3ca-4a00-abb5-98f72614618e-image.png

    So if you are editing an HTML file, and want to see that HTML file rendered in the Chrome browser, you use View > View Current File in > Chrome

  • Session.xml keeps getting deleted

    21
    0 Votes
    21 Posts
    3k Views
    donhoD

    @mkupper said in Session.xml keeps getting deleted:

    @donho may be feeling lonely and so should be happy to get a kudo for implementing the session.xml.inCaseOfCorruption.bak file thing.

    LOL!
    I love kudo, but all kudos should go to @xomx - thanks to his code review, the workaround of Dell Support Assist’s bug has been implemented in v8.6.5:
    https://github.com/notepad-plus-plus/notepad-plus-plus/pull/14858#issuecomment-1999912317

  • Fix corrupted txt file (NULL)

    114
    2 Votes
    114 Posts
    143k Views
    donhoD

    Hi guys

    Thanks to the investigation & implementation of @xomx , we have identified a plugin which could cause this issue eventually: “SaveAsAdmin”.
    ref: https://github.com/notepad-plus-plus/notepad-plus-plus/issues/14990#issuecomment-2053828749

    While browsing this very long discussion of the issue, I found no Debug Info regarding files corrupted NUL characters issue.

    So for people who have encountered NUL characters content problem, could you confirm (or deny) that you have had SaveAsAdmin plugin installed?

  • Custom file manager

    5
    0 Votes
    5 Posts
    465 Views
    Alan KilbornA

    is there any particular reason it isn’t possible to set a custom file manager?

    It IS possible, you just have to follow Peter’s suggestions.
    Of course, you probably mean some nice UI way of doing it…so, yes, that would involve a feature request and a hope that it gets implemented.

  • 1 Votes
    3 Posts
    230 Views
    CletosC

    Okey, thank you!

  • strange style glitches after crash

    1
    0 Votes
    1 Posts
    128 Views
    No one has replied
  • Language association with .jbeam files at JSON5

    3
    0 Votes
    3 Posts
    350 Views
    UDGU

    @PeterJones
    You are an absolute life (and time) saver, thank you so much for the help.
    I edited langs.xml and that did it.

  • App locking up every few minutes (NP++ 8.6.x, Win 11)

    13
    0 Votes
    13 Posts
    671 Views
    Lycan ThropeL

    @Alan-Kilborn ,
    Well, just so we can be clear, I’ve never really been an early adopter of OS’s as I prefer not to do their QA work. :-) And there have been many hiccups even between common NPP behavior and Win11 changes to warrant such a warning as a possible reason for problems. That’s all.

    When something changes, in this case the OS, that’s usually the first place to look for a change after the application has been cleared. That’s all.

  • Notepad++ Keeps Losing Track of my Recent Files

    6
    0 Votes
    6 Posts
    466 Views
    xomxX

    @Nicholas-Piazza said in Notepad++ Keeps Losing Track of my Recent Files:

    But lately (last few weeks (since January 2024),

    @Mauricio-The-Souza said in Notepad++ Keeps Losing Track of my Recent Files:

    but recently, this is not happing any more, the App usually opens totally blank

    Do you by any chance have also the Dell SupportAssist SW installed on your computers?

    (check if you have the C:\Program Files\Dell\SupportAssistAgent\SRE\SRE.exe on your disk, there is a proof that this external program, in its latest version updated in January 2024, is deleting the Notepad++ session.xml file)

  • Two Questions: (1) Batch replacement and (2) bulk file open

    2
    0 Votes
    2 Posts
    234 Views
    PeterJonesP

    @Vicky0878 ,

    Three moderator notes before moving on to your questions:

    Please reserve “Announcement” Topic replies for “regressions” – things that broke with a specific, recent release. Generic questions belong in Help Wanted, where I moved this to.

    It appeared that you had two distinct questions, so I used my understanding of those questions for naming the new Topic I (as a moderator) created to talk about your questions._

    It is best practice to create two different Topics in Help Wanted if you have two unrelated questions, which yours appear to be. But in case I’ve misunderstood, I have left them together. But you will likely find the discussion hard to follow, as some people will only reply to question 1, others only to question 2, and some to both.

    Regarding your questions

    in the batch replacement text I am limited by the edit box paste,

    The developer doesn’t believe that most search/replace need multi-line inputs. Using “Extended Mode” or “Regular Expression Mode”, you can use \r\n to indicate searching for a newline in the search sequence. If that’s not sufficient for you, there is a plugin called “MultiReplace” which you can install from the Plugins Admin: that will allow easy multi-line input for search and replace fields.

    About header display style when opening files in bulk I can’t find my files Where can you update him

    Under normal conditions, if there are too many files to view, there are little arrows at the right of the tab bar. (I have circled those in red in my screenshot):
    af270232-4da7-47e4-b3ce-2de844a04d77-image.png

    Also, Settings > Preferences > General has a section called Tab Bar, and if you checkmark ☑ Multi-Line. Ah, you probably have that set, because with 12 tabs and a narrow window, I get something like:
    34e30b50-8276-45be-a833-53953ed7abe3-image.png
    … which is similar to your right screenshot. If you don’t want your tab bar to wrap like that, turn off the option to wrap the tab bar.

    For other ways of finding the files when you have a lot open.

    In the Windows menu, if there are too many to fit, you can click on the Windows… action,
    8c9981a6-44b8-4fac-a41e-36b06b56e3dc-image.png
    … which will pop up a dialog which you can scroll and sort
    57e6808b-b731-4d4d-8901-50f5ff5f749e-image.png
    You can
    Further, View > Document List will open a Docked Panel which has an easy-to-use scrollbar for navigating between your documents.
    5105c2fb-8d2c-492b-829e-f7ab6093f517-image.png

  • Saved tabs disappeared with upgrade to v8.6.5

    5
    1 Votes
    5 Posts
    563 Views
    mkupperM

    @Vladimir-Krasko, @xomx posted a link to github where I see that you had provided your Notepad++'s Debug info. I see that you are using %AppData% which is Notepad++'s default.

    Take a look at the %AppData%\Notepad++ folder.

    When was the folder itself created? When was the session.xml file created?

    If you are using Windows Explorer to look at the %AppData%\Notepad++ folder then switch to the Details view and add the Created column to get the creation dates. If you using the command prompt then use dir /tc to view file or folder creation dates instead of the usual last-modified dates.

    If the creation dates are within the last few days then you likely are in luck as that means your previous installation of Notepad++ was storing its settings somewhere else.

    If your session.xml file was created weeks, months, or years ago then it likely was corrupted and so Notepad++ generated a new/empty session.xml file. Unfortunately, that also means the version of your session.xml that listed 100+ tabs was overwritten.

    You may see a file named session.xml.inCaseOfCorruption.bak but I suspect that won’t be useful in your case as Notepad++ overwrites it every time it exits.

  • How do i configure markdown (.md) display style?

    17
    0 Votes
    17 Posts
    6k Views
    Mark OlsonM

    If you can read C# code, you might look at the CSVLint CSV lexer, which may give you some insight into any differences between user-defined lexers and normal ones.

  • How to add .bas and .frm to Notepad++?

    2
    0 Votes
    2 Posts
    888 Views
    PeterJonesP

    @OvalPiston ,

    By default, .bas is associated with the Language > F > Freenbasic. If you look in Style Configurator, it should have FreeBASIC between Fortran and GDScript:

    3627a079-9929-4e39-8dd2-e3ecf6230d19-image.png

    If you don’t have that entry, then your stylers.xml (or whatever theme you’ve picked) is out of date, and doesn’t have that language; that might explain why the background is not matching (because nothing is defined). If you wanted to use FreeBASIC for .bas files, you could open C:\Program Files\Notepad++\stylers.model.xml, and then copy the FreeBASIC section into your active stylers.xml (usually in %AppData%\Notepad++\stylers.xml) or into your theme XML of choice. Restart Notepad++, and FreeBASIC should now be in your Style Configurator. (But you only need to bother with these steps if you want to use FreeBASIC syntax highlighting. If you want to treat .bas and .frm as Visual Basic, then see the next paragraph.) Alternately, maybe you’ll see FreeBASIC listed, but it will show background colors that aren’t as you expect – in which case, you could change the colors there, if you wanted.

    But you said you want .bas to apply to Visual Basic; to do that, you would change the VB / VBS language’s User ext.: settings. If you have it set to bas frm, like in my screenshot below, then .bas and .frm files will default to using the VB/VBS color settings.

    caad295f-726a-48c8-a69e-7bac29b5cd1e-image.png

    If you already have a .bas file open, it won’t immediately take effect (because Notepad++ decides on filetype when the file is first opened, so it will have loaded that file with .bas associated with FreeBASIC). Thus, if you close the file then immediately open it again (Ctrl+W, Ctrl+Shift+T), or open a new .bas that isn’t already open, Notepad++ will know to treat it as Visual Basic code rather than FreeBASIC code. And every one you open from now on will also follow Visual Basic syntax highlighting.

    ce96eed3-8d75-4bc5-b765-67f3650b3f7c-image.png

  • Search and replace/delete timestamps in brackets []

    2
    0 Votes
    2 Posts
    238 Views
    CoisesC

    @Poldi

    Select Search | Replace… from the main menu; then fill in:

    Find what: (\A|\R)\[.*?\]\h*
    Replace with: a single space
    Search Mode: Regular expression

    then click Replace All. (You’ll wind up with one extra space at the beginning of the file, which you can delete by hand.)

  • Special characters with unmapped "shortcut" combos

    11
    2 Votes
    11 Posts
    1k Views
    PeterJonesP

    @kuzduk-kuzduk,

    You earlier said,

    i dont understand why Don Ho do not off by default this Special characters with unmapped “shortcut”…

    And now you say

    Thanks, but this doesn’t work for me because I’m using npp 8.5.8

    I am sorry.

    Some applications use a model where they are able to release patch fixes to old releases of software; Notepad++ does not work that way. If there are bug fixes, they go in the next revision. So, to be able to get a fix, you have to be willing to update to a new version.

    (Yes, I said “willing” , not “able”, because despite your assertion, your choice to not upgrade Notepad++ instead of choosing to remap the weird PauseBreak global shortcut to something other than PauseBreak is just that… your choice. And it’s your choice to prioritize keeping PauseBreak over keeping )

    so sad, but [Alan’s script does] not work in russian layout

    As an alternative, figure out all the Ctrl sequences that type ASCII control characters based on your setup. Then create a NULL macro for each of those. A “NULL macro” is a “do nothing” macro. The scintilla action 2172 is a do-nothing/no-op/null-op action. So, you could insert a macro like the following into shortcuts.xml, then save and restart:

    <Macro name="NULL-CTRL-R" Ctrl="yes" Alt="no" Shift="no" Key="82" FolderName="Control Remaps"> <Action type="0" message="2172" wParam="0" lParam="0" sParam="" /> </Macro>

    This mapped macro it would stop Ctrl+R from inserting the DC2 ASCII 18 control character, and instead run a no-op command, making it “do nothing”.

    Creating multiple such macros, one for each unmapped sequence, would get rid of the accidental ASCII control characters in your documents. (And I showed putting it in FolderName="Control Remaps", so they would all show up in a sub-menu of Macros instead of cluttering your main Macros menu)

    -----

    update: earlier in this discussion, @Michael-Vincent linked to this old discussion. It turns out, my suggestion is essentially what Claudia suggested 8 years ago (good to know that her excellent answers have apparently become part of my subconscious mind), though she chose message 0 instead of 2172. And in this February’s replies to that ancient thread, @mkupper showed a mapping with lots of macros that show how to do the “one macro for each unmapped sequence” that I just suggested today. (Though I would again recommend changing to 2172, and I’d add the FolderName attribute to de-clutter the Macro menu.) And @Alan-Kilborn already made the 2172 correction in that other discussion. So basically, it turns out I said nothing new anywhere in the second half of this post of mine. ;-)

  • how to delete text in notepad ++

    8
    0 Votes
    8 Posts
    840 Views
    PeterJonesP

    @Mert-dirk said in how to delete text in notepad ++:

    then its not working do i miss something?

    You didn’t understand the regex, and randomly changed it, so of course it won’t give you the right answer.

    I will explain a few features of my regex that you apparently didn’t understand, and see if you can try to figure it out. I will link to each feature in the user manual so you can read more about it.

    (...) – things in parentheses go into “capture groups”, in order. Since I had two sets of parentheses, that goes into group1 and group2, which are referenced in the replacement as $1 and $2. \d – is a “single character match” for a “digit character” \d{N} – the {N} is a “multiplying operator”, which makes this sequence match "N digit characters .*? – “non-greedy” match “zero or more” of “any character” \w+ – “one or more” “single character match(es) for a word character

    So, what your edited regex is doing is saying "look for (localhost/wordpress/ followed by two digits then a slash then four digits then a slash) and put it all into group#1, then search for anything in between ending with a /, then (one or more word characters, followed by .jpeg ‡) and put the second parenthetical into group 2.

    With that, I hope you can figure out why your random edit didn’t work. And given that I told you what each section of the regex did, you should now know what to take out or move to get stuff out of the capture groups and into the in-between stuff, so that there is less in the replacement and thus, effectively, more is deleted.

    ‡: technically, it is any character followed by the literal .jpeg … but it will work for your purposes, unless you have other text that has some non-dot character before jpeg)

    And no, you got your freebie: I am not going to just hand you the answer a second time without you putting in a little effort. (And swapping a 2 and a 4 is not putting in effort; that was obviously a random guess on your part. Random guessing is not “effort”.)

  • How to change text particular row and column in notepad++

    6
    0 Votes
    6 Posts
    5k Views
    guy038G

    Hello, @shubhada-wavale and All,

    In this case, the regex S/R is greatly simplified !

    The generic regex S/R to use becomes :

    SEARCH (?-is)^.{O}\K.{N}

    REPLACE R

    Where :

    O ( for OFFSET ) represents the leading number of characters, of each line, to discard from the search

    N represents the number of characters to replace, in each line

    R represents the replacement expression to replace, in each line, the N characters, found after the first O characters

    Remarks :

    You must check the Wrap around option and select the Regular expression search mode

    Note that the replacement R may be an empty string if you want to delete the N characters of each line

    If the replacement part R contains parentheses, you must escape each of them with an antislash char

    For instance, given the text in the first post, above :

    <----------25-----------><-5-> 171TRM00009988000300032019060305 50533 TRANSFERENCIAS 2202019060320190603000300030000001 633001100119M00301100000001234545000000000000200+000000000000000 e ZAVALETA-RUIZ-CARLOS ENRIQUE 576704424233621544324211M00000051000300030000005 !052000040301336Calle Antonio Narino 272 Urb Ceres Ate Vitarte 000000000000000000000000000000JR MIROQUESADA 441 - LIMA 011011111411000101411 000300030000005 799D9900110011000000100030011ADDINTIONAL INFOR Z0000002 000300030000005 80000000005000000000110011000000000000001000000000000200000000000000000 000300030000001 90000010000000007000000000110011000000000000001000000000000200000000000000000~~~

    Then, the regex S/R :

    SEARCH (?-is)^.{25}\K.{5}

    REPLACE | This is a test |

    would change that text as below :

    <----------25----------->| This is a test | 171TRM0000998800030003201| This is a test |05 50533 TRANSFERENCIAS 2202| This is a test |0320190603000300030000001 633001100119M003011000000| This is a test |545000000000000200+000000000000000 e ZAVALETA-RUIZ-CARLOS ENRIQUE 576704424233621544324211M| This is a test |051000300030000005 !052000040301336Calle Ant| This is a test |Narino 272 Urb Ceres Ate Vitarte 000000000000000000000000000000JR MIROQUESADA 441 - LIMA 011011111411000101411 000300030000005 799D990011001100000010003| This is a test |DDINTIONAL INFOR Z0000002 000300030000005 8000000000500000000011001| This is a test |00000000001000000000000200000000000000000 000300030000001 9000001000000000700000000| This is a test |11000000000000001000000000000200000000000000000~~~

    Best Regards,

    guy038