Adding Useful SendTo Targets for Delphi and more…

With a new job comes very often the tedious work of installing/configuring a new workstation. There is one thing I find very useful and like to install almost at the beginning: a way to quickly open any file in a generic editor from a right-click menu in Windows Explorer.
I often want to quickly look at a Delphi project file (*.dpr) for instance without loading it in Delphi, or at a command file (*.cmd) with something better than regular Notepad, or at any file in an Hex editor…

Tedious iterative ways

There is a way to do it, going to the file extensions properties and adding there the alternative applications that can open this file type. It’s OK on a case by case basis, but not for the zillions you want to open in NotePad++.

I liked that Win7 is smart enough to remember that you already opened a given file-type with xyz.exe and now proposes it as an alternative when you right-click on this kind of files; but you still have to proactively and preemptively open an instance of each file-type you want.

Hijack the SendTo right-click menu

I much prefer to install broad spectrum targets in the “Send to »” menu. Any application that can load a file by passing its name in a command line parameter is suited to have a shortcut installed in the SendTo menu/folder.

1. To access the SendTo folder…

  • in Vista/Win7 : [Windows] key, then type shell:sendto
  • in XP : [Windows]+[R], then, in the run dialog, type shell:sendto
  • or from any Explorer window, type shell:sendto in the Navigation bar

There you can manually add the desired shortcuts.
They will show up in the regular or enhanced (special Win7 feature when using Shift + Right-click) menu.

2. To avoid remembering how to access the SendTo folder and automate the creation of SendTo items…

  • Open the SendTo folder (see above).
  • Navigate up to the parent Folder.
  • Create there a shortcut of the SendTo folder.
  • Name it as you like, for instance: Create Menu Item in SendTo.
  • Now move this shortcut into the SendTo folder.

And voila!

 

Usage: to add MyProg.exe in SendTo, just right click on a Shortcut for MyProg.exe, select SendTo | Create Menu Item in SendTo.

MyProg is in SendTo now!

Warning: If you do it with MyProg.exe instead of a shortcut, a copy of the exe will go in the SendTo folder.

This entry was posted in Configuration, Windows and tagged , , , , , . Bookmark the permalink.

11 Responses to Adding Useful SendTo Targets for Delphi and more…

  1. Ali says:

    Thanks for the “shell:sendto” shortcut.

    “I often want to quickly look at a Delphi project file (*.dpr) for instance without loading it in Delphi, or at a command file (*.cmd) with something better than regular Notepad, or at any file in an Hex editor…”

    For such purpose, I rather install Notepad++ it adds an item to file context menu “Edit with Notepad++”. Using this, not only you can quickly open whatever text-base file with syntax highlighting and auto-completion; you can also install its hex editor plug-in, and open any binary file with it too.

    Best Regards

    • François Gaillard says:

      Sure, but the technique can be applied to an existing application like Notepad or when the installer is not creating the right-click shortcuts. BTW, in this case (I’m on Win7 x64) I have the portable Notepad++ that is not doing the context menu…

      • Ali says:

        I have Notepad++ on Windows 7 64-bits, but it is the version with installer, not the portable one. Seems the options is available via the installer and the program itself does not provide any settings for it in its Preferences.

  2. I’m into a new job these days, browsing a lot of “foreign” and “strange” code…
    But I don’t need such hacks, because I’m using Total Commander since decades.
    You browse your files, then use F3 key to view it, it’s definitively faster than Notepad or Notepad++, and you navigate in the source code tree using only the keyboard.
    You have search and difference viewer at and, together with transparent zip archives browsing. Very very handy.
    I just added the ability to describe any Delphi project source code tree using our SynProject documentation tool (based on PasDoc), with external files. See http://synopse.info/forum/viewtopic.php?id=129 Therefore, you can document any existing project, without having to insert comments into the source code. Could be useful for you too, if your new employer doesn’t have any up-to-date technical documentation.
    In all cases, Total Commander is very productive. Couldn’t live without it. 😉

    • François Gaillard says:

      Interesting… One of the advantages of tailoring Windows Explorer to your needs that is worth mentioning though: it is ubiquitous in Windows applications. Any time you open a standard File Dialog, it is an Explorer and you have your right-click menu…

  3. fabio says:

    As a delphi programmer and as a programmer in general, I strongly suggest everyone to download and install the free FileBox Extender:

    http://www.hyperionics.com/files/index.asp

    This little gem is one of the most useful tool for a programmer. It is completely free and you have the sources too!

    [excerpted from the FileBox Extender home page]

    FileBox eXtender Features

    FileBox enhances Windows by adding several advanced functions to the standard Open File and Save File dialog boxes. (Note that if a program uses its own “private” dialog boxes for these functions, you won’t see our FileBox buttons, sorry.)

    FileBox adds two handy buttons to these standard dialogs. These appear on the right side of the Windows dialog box title bars. These buttons appear next to the minimize, restore, and maximize buttons with which you’re probably already familiar.

    FileBox can also forcibly resize the standard Windows file management dialog boxes so they’re bigger, and thus easier to use if you’ve got lots of files in a folder through which you need to look. The two pictures below show a small part of the Windows standard Open File dialog box:

    Standard Windows File/Save As… box
    with and without FileBox eXtender buttons

    These special buttons will appear for all styles of file dialogs (the old Windows 3.1 style file dialog boxes, new “Explorer” style boxes introduced with Windows 95, and even with the latest file dialog boxes in MS Office and Windows XP).

    And don’t worry—if you don’t like the pictures on our buttons, there’s a very easy way to change them.

    FileBox eXtender has a nifty option to display these buttons on Windows Explorer folders too, and this can greatly speed up navigation through today’s huge hard disks.

  4. Great tip!

    However, in the second to last screenshot it looks like you did do it with the application exe itself rather than a shortcut to it. Just saying… 😉

    I also never heard of the shell:-prefix before…

    • François Gaillard says:

      Yeah, that’s what I did first :-). This screenshot also had the mouse cursor in a misleading place. Uploaded the correct one.
      Makes the warning at the end all the more relevant 😛

  5. This is ingenious — “placing Send To in Send To”.

Leave a Reply to François Gaillard Cancel reply

Your email address will not be published. Required fields are marked *