How to make Windows Explorer treat a file with a `.MAS` extension as a regular file

3

1

I have a regular file on a Microsoft Windows 7 computer called MYFILE.MAS, as viewed from (e.g.) cmd.exe. (You can create one too, it's just an empty file). However, when viewing this file graphically with Windows Explorer, this file is treated differently than any other (e.g. to MYFILE.XYZ):

i1

(My view options should always show file extensions). Viewing the properties and attempting to use the right-click menu is different than any other regular file:

i2

I can't even rename the file in Windows Explorer to another extension (this needs to be done in a shell, i.e. mv MYFILE.MAS MYFILE.MAS1).

Is there a way to make Windows Explorer to treat a .MAS file extension as a regular file? I can't find any Microsoft documentation to suggest why this is happening. An no, I'm not doing anything related to Microsoft Access.


Update 1: In an attempt to remove any file associations, I've deleted the registry key, rebooted, and the key returns with these values:

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.MAS]

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.MAS\OpenWithList]

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.MAS\OpenWithProgids]
"Access.Shortcut.StoredProcedure.1"=hex(0):

The last one is strange, since some automatic procedure populated the data for this registry item as a "Microsoft Access Shortcut" (aka MAS).


Update 2: I found this registry item in [HKEY_CLASSES_ROOT\.mas]:

[HKEY_CLASSES_ROOT\.mas]
@="Access.Shortcut.StoredProcedure.1"

[HKEY_CLASSES_ROOT\.mas\Access.Shortcut.StoredProcedure.1]

[HKEY_CLASSES_ROOT\.mas\Access.Shortcut.StoredProcedure.1\ShellNew]

Deleting this key (and child members), then restarting explorer.exe makes .MAS files like any other regular file. Fixed!

Mike T

Posted 2016-05-18T03:48:31.387

Reputation: 664

This is an interesting issue .. just created a new text file, renamed to "blah.mas" and have the same symptoms .. it might be an installed office shell extension that's treating the .mas extension like a shortcut of types (which explorer does not show the extension of, since shortcuts have an extension of .lnk in cmd.exe for example) .. doing some more invoostigating as that's a head scratcher – txtechhelp – 2016-05-18T04:50:04.570

@txtechhelp yes, this is just like a regular file bla.lnk, which behaves differently than other regular files. But just to Windows Explorer. This could be related to How do I “persuade” programs open an actual .lnk file in Windows 7?

– Mike T – 2016-05-18T04:57:09.580

I feel like I'm playing an old version of some DOS game with the Windows Registry sometimes .. gotta find the hidden key to unlock the magical door before the healing fairy reveals itself .. only to find that I need the BLUE key 10 levels over :/ ..... – txtechhelp – 2016-05-18T05:05:18.567

If you have found a solution then you should post it as an answer rather than editing it into your question. – Mokubai – 2016-05-18T05:50:13.083

Answers

1

The solution was to find the HKEY_CLASSES_ROOT\.mas registry key, export it (for safe keepings, in case things go wrong; a copy of mine is in Update 2 of the question), then delete the registry item.

After restarting explorer.exe, any file with a .mas file will be treated by Windows Explorer as a regular file.

Mike T

Posted 2016-05-18T03:48:31.387

Reputation: 664

What is the .mas files and how can I open them, – Mohamed Badr – 2017-07-17T17:09:55.007

1File extensions only have significance to certain programs they are registered to, otherwise it's just a name of any arbitrary file. You'd need to investigate the source if the file to get a better idea of what software to open them. The ones I use are text, so I use a text editor to open. – Mike T – 2017-07-18T19:15:53.297

2

Thanks to some help from this link, turns out, it's a registry value that (when added), makes the shell extension hidden, called (innocuously enough) NeverShowExt, as well, the IsShortCut key will treat the file as a shortcut (which is why you see the little shortcut arrow). Specifically for my registry the key was at [HKEY_CLASSES_ROOT\Access.Shortcut.StoredProcedure.1]

Doing a search and scrub for these keys will show all "hidden" extensions; note though that you'll need to kill then restart explorer.exe from the task manager (or reboot) for the removed keys to take effect.

Hope that can help.

txtechhelp

Posted 2016-05-18T03:48:31.387

Reputation: 3 317

It was close! I've fixed it by deleting [HKEY_CLASSES_ROOT\.mas] – Mike T – 2016-05-18T05:09:42.047

@MikeT, Ahh, so it was the BLUE key! :) – txtechhelp – 2016-05-18T05:15:02.833