August 17th, 2021

Is it expected that custom default pinned taskbar items via LayoutModification.xml keep coming back each time the user logs on?

A customer was using the LayoutModification.xml file in their operating system image in order to pin a few applications to the taskbar automatically. They found that if the user unpinned those items, that seemed to work okay, but once the user logged out and back in, the pinned items came back. They wanted to know if this was intended behavior.

Yes, this is intended behavior, as spelled out in the documentation:

If you use a provisioning package or import-startlayout to configure the taskbar, your configuration will be reapplied each time the explorer.exe process restarts. If your configuration pins an app and the user then unpins that app, the user’s change will be overwritten the next time the configuration is applied.

The paragraph also tells you what to do if you want user changes to be preserved:

To apply a taskbar configuration that allows users to make changes that will persist, apply your configuration by using Group Policy.

On the other hand, if your goal was to apply a configuration that users cannot change, then it is typical to hide the weirdness of “I unpinned this app, but it keeps coming back” by preventing them being unpinned in the first place: Couple the LayoutModification.xml file with the NoPinningToTaskbar policy, which preserves existing pins but does not allow the user to pin new apps or unpin old ones.

Author

Raymond has been involved in the evolution of Windows for more than 30 years. In 2003, he began a Web site known as The Old New Thing which has grown in popularity far beyond his wildest imagination, a development which still gives him the heebie-jeebies. The Web site spawned a book, coincidentally also titled The Old New Thing (Addison Wesley 2007). He occasionally appears on the Windows Dev Docs Twitter account to tell stories which convey no useful information.

2 comments

Discussion is closed. Login to edit/delete existing comments.

  • Jeff Jerousek

    Thanks, I didn’t know that this was possible.

    Probably because this is the exact opposite of how to allows users to make changes to the Start Menu that will persist.

    • James

      Classic Microsoft