Preserving Windows Explorer Folder Views in Roaming Profiles
|
by Nicholas Dille on 02/17/2009 | 12 Comments | 12,295 Views
|
A user environment usually includes one or more network drives used to store data and exchange documents. Over time many different types of files are located on these shares and many make use of different views for individual folders (details, list, small and large symbols to name a few) to present the contained files in the most appropriate way.
But due to the design of roaming profiles, Microsoft has decided to not preserve these folder views in most situations. This restriction does not become apparent in environments deploying fat clients because users do not work on different machine regularly. When using Terminal Services to deliver workspaces, users often switch servers due to load balancing across all members of the farm. Every time a users logs on to the next server, all views for folders accessed through a drive letter assignment are erased. It is assumed that these locations may not be the same when working on a different machine. But in a standardized environment using Terminal Services, all servers are configured identical. In addition, the user is provided with several network shares (accessed through a standardized drive letter) to access company resources and his personal data. Therefore, this measure is antiquated.
Shell[NoRoam]
Let’s have a quick look at how Windows stores views for individual folders. This information is located in two registry keys Shell and ShellNoRoam under HKCU\Software\Microsoft\Windows\CurrentVersion. It does not come as a surprise that all folder views written to ShellNoRoam are discarded when logging on to another machine.
To determine when a user switches machines, the default value of the key ShellNoRoam (which is a REG_SZ) contains the name of the machine responsible for the configured folder views. During logon, userinit.exe compares this value with the name of the current machine and erases all sub keys when the strings do not match. The value is then filled with the new name.
This behaviour is overridden by a setting deployed by group policies which can be used to deactivate saving folder views between sessions all together. Apparently, this makes folder views completely unusable.
Solution
The behaviour of userinit.exe relies on the data of the default value of the ShellNoRoam key. The following command changes the type of the value to REG_EXPAND_SZ which causes userinit.exe to evaluate variables contained in the value. In the same process it writes %ComputerName% to the value. This results in all machines recognizing the content of the key ShellNoRoam as information created previously on the local machine.
%WinDir%\system32\reg.exe add
HKCU\Software\Microsoft\Windows\ShellNoRoam /ve /t REG_EXPAND_SZ /d
^%ComputerName^% /f
Obviously, this modification changes the way Windows was designed to work. Please evaluate this fix in a pre-production environment!
Is Citrix User Profile Manager vulnerable to this problem?
The behaviour described above is not limited to roaming profiles as one might think due to the name of the registry key ShellNoRoam. It rather identifies the process of logging on to another machine, i.e. roaming.
Therefore, a user profile needs to be prepared to prevent folder view settings from being deleted upon login. This necessity applies to all environments and user profile solutions.
References
MS KB: How to modify your folder view settings or to customize a folder
MS KB: My view settings or customizations for a folder are lost or incorrect
- ‹ previous
- 37 of 106
- next ›
+++ Profile Migrator 2 - Ein neuer Desktop, ein frisches Benutzerprofile und alle bewährten Einstellungen und Daten. Jetzt kostenlos und unbefristet testen!
12 responses for "Preserving Windows Explorer Folder Views in Roaming Profiles" |
Add Comment
Aktuelle Artikel
Über den Autor
![]() |
Nicholas Dille Head of Technology and Innovation Blogs about Centralized computing, virtualization and performance monitoring |
Most viewed
| 18,518 Views |
Who Needs Aero Glass Remoting? Although It's Cool! |
| 15,759 Views |
Emulating a Redirecting Load Balancer for WI and PNA |
| 14,224 Views |
Building Custom EdgeSight Reports Part 4 - The Wedding |







[...] Were I German, I would
[...] Were I German, I would want to be working for sepago. These two articles are great - Mandatory Profiles - The Good, the Bad and the Ugly and Preserving Windows Explorer Folder Views in Roaming Profiles. [...]
Awesome article and
Awesome article and information Nicholas.
Thanks for the informative
Thanks for the informative article, however you state:
"This behaviour is overridden by a setting deployed by group policies which can be used to deactivate saving folder views between sessions all together. Apparently, this makes folder views completely unusable."
Any idea which group policy setting overrides the default behavior?
I am battling this issue and I must have something setup in my GPO applied to my teminal servers, but for the life of me I can can not figure out what.
If I deny my GPO to my test account my folder view settings are preserved across all servers in my farm and the computer name is written to HKCU\Software\Microsoft\Windows\ShellNoRoam without issue.
Hey Nic, this might save me
Hey Nic,
this might save me from further calls ;-)
I'll check it in a minute.
Thanks, Dirk
Matt, I have not been able to
Matt,
I have not been able to collect and post the information. Let me get back to you as soon as possible.
Sorry for the delay,
Nicholas
Nicholas, I have been
Nicholas,
I have been reading some of your stuff, excellent work.
I am currently working on trying to get explorer settings/views for folders to roam with a Server 2008 cluster.
Unfortunately, there is no longer a ShellNoRoam key, and thus far any attempts to copy just the Bags reg key under Shell from TS to TS has proved inconsistent at best.
Here is a guy with my setup almost to the letter:
http://connect.microsoft.com/WindowsServerFeedback/feedback/ViewFeedback...
Do you have any experience or ideas on getting something like this to work under 2008? Does sepago offer anything that could do this (guessing not since we aren't running Citrix ;).
Not looking for a gift, just some guidance. If you have any suggestions on another place to look, I would love to hear.
Keep up the good work, have a good one!
Josh
Matt, sorry for taking so
Matt,
sorry for taking so long to answer.
You can disable individual folder views to be saved by setting the registry value "ClassicViewState" to "0x1". It is located in "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced". You will have to create a custom ADM template to be able to deploy this setting.
Note that this setting is not managed. Also note that users will be able to change this setting but it gets overwritten after each and every logon. Therefore, you should deny access to the folder options using the following GPO: User Configuration \ Administrative Templates \ Windows Components \ Windows Explorer \ Removes the Folder Options menu item from the Tools menu.
Regards,
Nicholas.
[...] one of my previous
[...] one of my previous articles I explained how Windows handles folder views and how to preserve these settings for network shares when using roaming profiles across multiple machine. A reader has [...]
Josh, the handling of folder
Josh,
the handling of folder views has changed in Windows Vista and Windows Server 2008. Network drives are, again, not handled in the same location as local drives. I have documented the behaviour in a new article: http://blogs.sepago.de/nicholas/2009/04/21/how-vistaserver-2008-handle-f....
I hope this information helps.
Regards,
Nicholas.
[...] a previous article, I
[...] a previous article, I described how Windows XP and Server 2003 handle folder views, why those configured for network [...]
I have this problem
I have this problem regardless of roaming. Each time i close windows explorer it loses
its window size and position. It appears to not to write the information to ShellnoRoam as expected.
It seems to be a group policy setting that is causing it as logging on with a local account on the same server does not exhibit the problem.
If anyone know what policy setting upsets this please post.
thx
David
www.thinworld.net
In answer to my own question
In answer to my own question i posted here, the Group policy that can impact playing with
shellnoroam and Shell registry areas is the "dont save setting on exit" setting under user config\admin templates\desktop
Ive added info on this on my blog www.thinworld.net\blog
Thanks
David