Hot answers tagged

2

I would say that Notepad++ is not the tool to do this job. Instead, I would suggest that you use a scripting language of some kind to iterate thru the files, then iterate thru the lines, replace the single line (if it exists), and then save the file. Here's a PowerShell script that will do that: # Set by user to their needs. $filesToCheck = "C:\path\to\...


2

I think the best you can currently do is to use Document Switcher instead of tabs: Filenames there are displayed on area which has fixed width so this is close to what you request. You can adjust the width as you wish. You can set it up in menu Settings > Preferences and also disable the tabs which are no longer needed: Regarding tab width of tab ...


2

This is not possible. Notepad++ uses the Scintilla editor component which doesn't provide this feature. Yes, it will increase the horizontal scroll range but it won't reduce it. Here's the relevant part from the documentation (emphasis mine): If scroll width tracking is enabled then the scroll width is adjusted to ensure that all of the lines currently ...


2

Your regex as it stands will replace the whole end of the line, so the best bet is to take the whole line, check it for a semi, and only replace the section that needs it (eg add a semi). (.*)([^\;])(\r\n) is an expression with 3 capture groups: (.*) -- the first part of the line ([^\;]) -- the check for the missing semi (\r\n) -- the line ending So, ...


1

Use Find What: ([^\;])\r\n Replace with: $1;\r\n It will replace the last character with the same character + ';' unless it is ';' Also, in 'replace' '\' is not needed before ';'


1

NP++ isn't to blame. Try directly replacing the page's html using Chrome's console: document.open(); document.write("<?php echo 'egfwe'; ?>") document.close() It turns into a comment, without even being touched by NP++, because those tags aren't valid HTML. This is because to run PHP code, you need an actual server to execute the code (since PHP ...


1

To replace the selected line in all opened files you need to do 2 steps: Select the line you want to replace and do "Find in files": Replace in all opened files:


1

You could do something like this on the command line: for /f "tokens=*" %f in ('dir /a-d /b /s "C:\PATH\TO\FOLDER"') do notepad /p %f That will loop through all files in C:\PATH\TO\FOLDER and execute notepad /p, which prints the file to the default printer.


1

Here is a REG file that sets IE as the default browser (except for HTM and HTML file types), and then associates HTM HTML and CSS files with Notepad++ Note: This registry edit won't work if you're using Windows 10.. as Windows 10 imposes strict rules pertaining file type associations - with the hashing algorithm in place to detect any tampering with User ...


1

Go to Edit > Line Operations > Remove Empty Lines


1

Why? I have discovered the reason why only recently, so I might as well share it here. Well, it's one of the reasons or one of the possible scenarios. First of all, I only started using the Hex Editor plugin for Notepad++ only recently. So I was not aware that Notepad++ had stability issues with this plugin. But it figures! The plugin has not been updated ...



Only top voted, non community-wiki answers of a minimum length are eligible