Cracking the binary (aka How to open .MUI files?)

by Michael S. Kaplan, published on 2007/10/05 10:31 -04:00, original URI:

Developer Andrew asked:

Can anyone suggest how to view/dump resources in readable format from mui file?

I need to find out if a MUI file contains particular dialog resource or string resource.


And I figured as long as I was going to answer Cory's .MUI file question, it might be a good time to answer this one. :-)

Lily, one of the great SDE/Ts in Windows International (and someone who has probably had to deal with this very problem in the past many times!) pointed out something that most people don't realize (in fact in a casual survey of developers at Microsoft outside of our building, fewer than 20% of them knew it, including me!):

You can rename the MUI file, e.g. foo.dll.mui to foo.dll,  then open it using Visual studio.

And then ace developer Jay pointed out something that I did know about (though not as it relates to .MUI files since as I mentioned I did not know that they were DLLs):

You don't have to rename the file.
In the VC dialog boxes there is an "open as" or "open with" drop down.
Select "resources" or "resource editor".
It's also trivial to write a custom dumper yourself starting with  the EnumResource APIs...

It is actually amazing how rich some of the VS functionality is that is hidden by its own notions of "known file types" for various operations. It is very easy to override, too -- something that I hope gets to be even more intuitive.

And maybe in some future version (since they are going out with a resource compiler that can build .MUI files) they could put them on their list of known binaries for resource loading!

In the meantime, it is nice that this feature simply works. :-)


This post brought to you by    (U+0fbe, a.k.a. TIBETAN KU RU KHA)

Krishna Kumar on 25 Feb 2010 3:57 AM:

Hi Thanks for the valid information, but how windows will use this files internally, what will happen when i click right click on desktop. How windows will display the context menu. Which message handler will get execute when i click refresh?

Thanks in advance.

Michael S. Kaplan on 25 Feb 2010 10:10 AM:

They are DLLs that hold resources, but the Shell doesn't think of them that way. So they look like unknown files....

Vinzy on 10 Aug 2010 2:16 PM:

Is there a way to read strings from loaded MUI files, say shell32.dll.mui using C#?

Michael S. Kaplan on 11 Aug 2010 8:05 AM:

Vinzy, see here for the response to your question....

ph_arnaud on 17 Jan 2011 9:40 AM:


I try to modify some dialogs or strings of a MUI opened in Visual Studio 2008/2010 (using Visual Studio as a sort of binary editor) and save, but there is an error saving ("Cannot save file").

Why can Visual Studio modify and save other Win32 (non MUI) dlls with resources, but not MUI format files?

I tried with both a test app I created using MUIRCT.exe and also with the notepad.exe.mui file.  Same results.


Michael S. Kaplan on 17 Jan 2011 10:02 AM:

Modifying Microsoft Windows's own binaries is an unsupported violation of the Windows license....

ph_arnaud on 18 Jan 2011 6:09 AM:

The purpose and question is to localize/translate our own MUI app with a binary localization process.

Since the binary loc tool was able to load our .MUI file, but not save it, I tried to do the same modification to our .MUI file with Visual Studio 2008/2010 (which normally has the capability to modify the resources of Win32 res.dlls binaries.)

Visual Studio shows the same behavior as the binary localization tool, it can load, but not save our .MUI file.

Can Visual Studio modify and save any .MUI files?

I'd expect yes since the help says the .MUI file is just standard Win32 resources with a new resource type of MUI, and the help does mention the possibilty of binary localization.

As soon as I delete the custom RCDATA resource of type "MUI" Visual Studio can save the file successfully, except of course the file is not a valid MUI one without the MUI resource.  If I change the MUI resource number to something different than 1 (the default), it also saves successfully, but of course it needs to be 1, to work as a MUI file.


Michael S. Kaplan on 18 Jan 2011 6:36 AM:

Visual Studio is (as the blog indicates) rather ignorant of .MUI files, and it is also not a typical localizer's tool. There are several tools inside and outside of Microsoft that do a good job of binary localization with .MUI files and they *are* tools that localizers use, so generally I'd push people in that direction before I'd hope for VS to shore up the scenario....

ph_arnaud on 19 Jan 2011 2:46 AM:

From a few more tests, I find that our binary localization tool and Visual Studio 2008 can open/edit and save the .MUI file on Windows XP.

However on Windows Vista and Windows 7, neither our binary localization tool nor Visual Studio 2008 can save the .MUI file anymore (open/edit still ok).

Michael S. Kaplan on 19 Jan 2011 5:48 AM:

I don't know what your tool is, but there are tools both inside and outside of Microsoft that are able to work here, even if VS or your tool do not. My answer is the same....

Uwe Philipps on 9 Sep 2011 1:48 AM:

Is there a documentation of the resource configuration data within a .mui file? It's in the "MUI" resource.

I'm developer for one of the "tools outside Microsoft" for software localization, and we need to modify/create the MUI resource data.

anmol on 11 Jun 2012 2:30 AM:

i have recently downloaded a theme file of mui format but how cn i open it i dint know .please help me

Mohammed Goder on 27 Jun 2013 9:38 PM:

Just use ResHacker:

referenced by

2011/03/11 A resource segue, #2 (architecting the wheels off the wagon, a bit)

2010/08/11 Loading the strings from the MUI file?

go to newer or older post, or back to index or month or day