8

One can choose what application to use for opening a file with

  1. Right click on the file
  2. Open with
  3. Choose default program...
  4. Browse

In this way, one navigates to the directory (say, C:\dir_new) containing the intended app (say, myapp.exe).

If it happens that the filename of the selected executable file (will call it Selected, in this case C:\dir_new\myapp.exe) is the same as that of another application (will call it First, e.g., C:\dir_old\myapp.exe) already present in the displayed "Open with" window, then instead of adding Selected (C:\dir_new\myapp.exe) to the list, it selects the already present First (C:\dir_old\myapp.exe).

Is it possible at all (by any means) to have two applications with the same file name (myapp.exe) available for "Open with" at the same time?

PS: I am using Windows 7, but I doubt this does not happen in other versions.


EDIT: I have just found this question. It is similar, but its aim is getting rid of a problem, instead of being able to have the two apps available simultaneously. At any rate, the accepted answer might perhaps be used for the present purposes. It requires admin privileges, though.

This and this may also be relevant.

2
  • Was hoping that this might have a solution by now...
    – Eric
    Jul 28, 2014 at 8:53
  • @Eric - I wonder if one can set a shortcut to C:\dir_new\myapp.exe, with a different name, and request opening with the shortcut... I would likely not be able to do it due to corporate restrictions, but perhaps this works for you. Jul 28, 2014 at 12:50

2 Answers 2

5

I found a workaround, if you have admin rights (and sufficiently modern Windows, I think Vista and above) you can use mklink to create a hard link (if your not familiar with UNIX-like system, it's basically a very low level shortcut) as follows:

C:\app1\app.exe <- Current app associated with filetype
C:\app2\app.exe <- Windows can't use this exe

In the windows command promt, run:

mklink /H C:\app2\hard_link_to_app.exe C:\app2\app.exe

Then the file C:\app2\hard_link_to_app.exe appears and can be used in place of C:\app2\app.exe for purposes of file associations.

I don't know if this can cause problems in some situations, so far it has worked well for me.


I wonder if one can set a shortcut to C:\dir_new\myapp.exe, with a different name, and request opening with the shortcut.

The above suggestion from the comments does not work with regular windows shortcuts.

2
  • If you want to post comments then you should answer the question, so you can get reputation, and thus so you can comment on questions and answers from other people.
    – Ramhound
    Apr 7, 2015 at 13:19
  • Important to note is that the link should reside in the same directory as the original exe if it relies on the executable path for loading auxiliary files (dlls and such). Sep 19, 2017 at 9:03
1

Here is a way to fix this manually:

Find the registry folder
\HKEY_CLASSES_ROOT\Applications&lt;executable name to update>\shell\open\command
and edit/update the only key existing in that registry folder by setting the new path of your application.

My scenario (if you have time to read)

I got the same issue with VLCPortable.exe when I wanted to open a .mp4 file with the new portable version I download on my dropbox folder. Using "open with" action of explorer contextual menu to associate mp4 extensions to this nex version did not work. Old VLC was still opening my video file. I discovered that an old portable version was also installed in a subfolder of C:\Portables and it was not the, same, old version of VLC already in my dropbox. I use task manager to figured out this, by displaying hidden column "command line" It seems windows is really checking only the name of executable and not the path or drive letter for file association.

So in my case <executable name to update> is "VLCPortable.exe". After the fix, i did not even need to associate all video extensions again... Which is perfect because there is a lot of video extensions !

1
  • This didn't help me directly, because my program was not on that path. But it pointed me on the right direction. Searching for the executable name on the Registry might lead you to the file type directly on HKEY_CLASSES_ROOT, which will have the shell/open/command key you can change. I did and it works perfectly.
    – Danita
    Sep 24, 2020 at 12:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .