Suggestion about Right Click Context Menu
-
Hello,
few days ago I asked another community question about context menu when open specify file - my goal was start editing every file ps1 from line 450, and today I get to the point where I know for sure its can be done with registry by simply add in there something like this:
[HKEY_CLASSES_ROOT\SystemFileAssociations.ps1\Shell\Edit with Notepad++ from line 450\Command]
@=““C:\Program Files\Notepad++\notepad++.exe” “%1” -n450 %*”There is only one thing missing - icon on the left side, but of course command is working fine - after click on in every selected file is started from this line.
So my suggestion for future development of this great tool can be add (somewhere in NP++ options) possibility to activate this for every file or provided extension, where user for example can decide from what line like to starts from, and also this could be for more that one line to choose like:
I think this can be helpful to users who works on some templates where pattern is always editing files from the same starting position.
-
@Maciej-Zet, you can add the icon yourself! I believe this is all you need to add:
[HKEY_CLASSES_ROOT\SystemFileAssociations\.ps1\Shell\Edit with Notepad++ from line 450] "Icon"="C:\\Program Files\\Notepad++\\notepad++.exe"
For others who want to make a similar change, here’s everything, including one line that wasn’t provided:
[HKEY_CLASSES_ROOT\SystemFileAssociations\.ps1\Shell\Edit with Notepad++ from line 450] @="Edit with Notepad++ from line 450" [HKEY_CLASSES_ROOT\SystemFileAssociations\.ps1\Shell\Edit with Notepad++ from line 450\Command] @="\"C:\\Program Files\\Notepad++\\notepad++.exe\" \"%1\" -n450 %*" [HKEY_CLASSES_ROOT\SystemFileAssociations\.ps1\Shell\Edit with Notepad++ from line 450] "Icon"="C:\\Program Files\\Notepad++\\notepad++.exe"
NOTE: If you’re using the 32-bit version of Notepad++, change the folder from
C:\\Program Files\\Notepad++\\
toC:\\Program Files (x86)\\Notepad++\\
(or wherever you installed Notepad++). -
@pbarney BIG thanks as this is was I looking for.
Just for the record - just checked and 2 entries is also fine:Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\SystemFileAssociations\.ps1\Shell\Edit with Notepad++ from line 450\Command] @="\"C:\\Program Files\\Notepad++\\notepad++.exe\" \"%1\" -n450 %*" [HKEY_CLASSES_ROOT\SystemFileAssociations\.ps1\Shell\Edit with Notepad++ from line 450] "Icon"="C:\\Program Files\\Notepad++\\notepad++.exe"
and perfect icon appear :)