How do I create a shortcut in the Send To menu that runs a program with a command line option?

Raymond Chen

To add an item to your Send To menu, create a shortcut in the Send To folder. The easy way to do this is to open an Explorer window and type shell:sendto in the address bar. This will take you straight to the Send To folder. From there, you can right-click an empty space and select NewShortcut, and then fill in the information about the program you want to send to.

The default behavior is to run the shortcut target with the file on the command line. But what if you want the program to run with a special command line option?

When you fill in the information about the shortcut, include the command line options when you say what you want to be a shortcut to:

What item would you like to create a shortcut for?
This wizard helps you to create shortcuts to local or network programs, files, folders, computers, or Internet addresses.
Type the location of the item:
notepad /a   Browse…

Here, I’m creating a shortcut to Notepad with the command line option /a which forces a file to be opened in the ANSI code page.

If you right-click a file and send it to this shortcut, it will run Notepad with the /a command line option.

Bonus: Send To simulates a drop on the shortcut, and this technique applies generally to drag/drop operations on shortcuts: Create a shortcut anywhere using this technique, then drop a file on the shortcut. It will open Notepad with the /a command line option.

0 comments

Discussion is closed.

Feedback usabilla icon