Common Tasks Don’t Match Folder Type

by Keith Miller

For reasons unknown, some users find that drives or system folders display the wrong tasks relative to the folder contents.  The C: drive may display music tasks; The ‘My Music’ folder may display picture tasks, etc.  While user-created folders allow access to the ‘Customize’ tab in the ‘Properties’ dialog, drives and system folders do not give you this option. 

There are two solutions to this problem.  The first is simpler and quicker, but the user will lose all saved views for his or her folders.  The second will allow the user to repair only the folder in question, but requires a bit of detective work. 

Solution 1 (All saved views will be lost)
 

  1. Start Registry Editor (regedit.exe)
  2. Backup these regkeys: (as a precaution only; if satisfied with the results, you may delete the backups)

    [HKEY_CURRENT_USER\Software\Microsoft\Windows\ShellNoRoam\BagMRU]
    [HKEY_CURRENT_USER\Software\Microsoft\Windows\ShellNoRoam\Bags]
     
  3. Delete the above keys.
  4. Restart windows to take effect.

Solution 2 (Repair only the folder in question) 

The folder type is stored in the registry under:

HKEY_CURRENT_USER\Software\Microsoft\Windows\ShellNoRoam\Bags

This key has a number of numbered sub-keys, each corresponding to saved settings for a folder.  The bad news is that the numbering is based on the order in which you opened the folders since you installed XP; there is no correspondence between name & number.

Each numbered key has a sub-key named 'Shell' with a number of values.  The value named FolderType is the one you are interested in. Some of the valid values are: 

Standard Templates               System Templates                 Other
'Documents'                              'MyDocuments'                        ‘UseLegacyHTT’
'Pictures'                                   'MyMusic'
'PhotoAlbum'                            'MyPictures'
'Music'                                      'MyVideos'
'MusicArtist'
'MusicAlbum'
'Videos'
 
The standard templates correspond to the available options under the ‘Customize’ tab.  The system templates belong to the folders of the same name.  ‘UseLegacyHTT’ applies to folders with a custom template defined in desktop.ini (thanks to David Candy for that tidbit). 

  1. Download & install Regmon: http://www.sysinternals.com/ntw2k/source/regmon.shtml
  2. To reduce the amount of information displayed in Regmon, under ‘Edit’ > ‘Filter/Highlight…’change include filter from '*' to 'SetValue*Bags'.
  3. In Regmon, go to 'Options' and clear the checkmark next to 'Capture Events', then go to 'Edit' and select 'Clear Display'.
  4. Open Explorer to the folder in question and change the current view to something different (icons > list); it doesn't matter what, just so long as there is a change.
  5. Switch to Regmon and select 'Options' > 'Capture Events'.
  6. Close the Explorer window.  Explorer waits until closing to save your settings.
  7. Regmon should now show a series of changes with a path similar to the following. You’re interested in the bag number:

    HKEY_CURRENT_USER\Software\Microsoft\Windows\ShellNoRoam\Bags\bag number\Shell\…
     
  8. Once you have the bag number, navigate to the ‘shell’ subkey of that key in the registry, locate the value named 'FolderType' and change it's value to the appropriate value from the list above.
  9. You should see the change when you reopen Explorer.  There was no need to logout or restart when I tested this.

XP Support- 01/01/2005 12:42 AM - Home Page WinXP
© Copyright Kelly Theriot MS-MVP(DTS) 2005. All rights reserved.

Hit Counter