The "Edit"-verb really does trigger the "Edit"-action.
(I tested it with changing the "Edit" for
.reg files in the registry and running the command.)
Since you made your answer "a partial answer" did you want to know how you would do this in
cmd.exe? I don't think it can be done natively in `cmd.exe'.
There is of course ShelExec.
But you can also run
powershell -command "start -verb edit textfile.txt" in
You can even put this in a shortcut with
doskey like this:
doskey cmdedit=powershell -command "start -verb edit $1"
Now you can do
cmdedit textfile.txt on the
Note: for the doskey-'macro' to be available after restarting the computer/cmd-session you need to add this command in your startup-scripts. You can look here for some suggestions to making it permanent.
I would go for the option of putting it in
.reg file does it all for you:
Windows Registry Editor Version 5.00
"AutoRun"="doskey cmdedit=powershell -command \"start -verb edit $1\""