Associate MP3 files to MPG123.EXE with parameters in Windows 7

0
3706

I recently saw a question over at Stack Overflow on how to associate MP3 files with a particular MP3 application with command line arguments and I originally thought – yeah there are plenty of examples on how to do this out there, but as it turns out there really aren’t that many explanations out there. So here’s one way to specifically achieve what the OP wanted to do in this question. I am also assuming the OP wanted to kick it off minimized. With all that in mind, here’s a process that should work on a Windows 7 machine. In any case, this solution should work for other purposes with a little tinkering.

I figured given the screenshots, the response to their question would be too bulky to stick into the answer column.

DISCLAIMER: WARNING – EDIT THE REGISTRY AT YOUR OWN RISK. IT IS ASSUMED YOU KNOW WHAT YOU ARE DOING. SERIOUS ISSUES CAN OCCUR IF MISTAKES ARE MADE!

1. Open the Registry editor and navigate to COMPUTERHKEY_CLASSES_ROOT.

2. We are going to assume that the .mp3 key already exists. In the example below, .mp3 was already associated with some other player so we simply navigate to the .mp3 key from HKEY_CLASSES_ROOT (If the .mp3 key does not exist, simply create it and update the (default) value as depicted below).

Change the (Default) Value to a name of your chosing – we will be using this name later when defining our launch action. In this case, we are going to set up our player to run with MPG123.exe so we have decided to use “MPG123Player.AssocFile.MP3” as our tag name (you could use “BOB” or anything at all really – so long as it doesn’t exist already in the regsitry at the location specified in the next step)

UpdateRegistryKeyAssociationDefault3. Navigate back to HKEY_CLASSES_ROOT and right click to create a new key – MPG123Player.AssocFile.MP3 as depicted in the screenshot.

CreateNewRegKey-Root

4. Underneath the newly created key HKEY_CLASSES_ROOTMPG123Player.AssocFile.MP3, create a key called Shell as depicted below.

CreateNewRegKey-subkey-shell

5. Underneath the newly created key HKEY_CLASSES_ROOTMPG123Player.AssocFile.MP3Shell, change the default value to “Open”

CreateNewSubKey-Default

6. Now we need to create another subkey under HKEY_CLASSES_ROOTMPG123Player.AssocFile.MP3Shell called Open

CreateNewRegKey-subkey-shell-subkey-open

7. Underneath the newly created key HKEY_CLASSES_ROOTMPG123Player.AssocFile.MP3ShellOpen, create a key called Command.

CreateNewRegKey-subkey-shell-subkey-open-subkey-Command

8. Change the default value under HKEY_CLASSES_ROOTMPG123Player.AssocFile.MP3ShellOpenCommand to the command string required to open the file.
In our example, we have MPG123.exe located under the folder “C:MPG 123”. We are running it like this because we want it to start minimized and quiet. If your MPG123 folder is somewhere else, make sure you change this:

cmd.exe /c start /min “MP3:%1” “C:MPG 123MPG123.exe” -q “%1”

CreateNewDefaultForMP3Ext

LEAVE A REPLY

Please enter your comment!
Please enter your name here