9

I have a corporate laptop which is managed by my organization. Each time Windows starts, IE and Windows Explorer are automatically pinned to the taskbar.

This is kind of neat, but I am wondering how it is done (the few desktop IT guys I asked were not sure, as they didn't setup that part). On my personal devices, when an icon is pinned or unpinned, a reboot does not affect icons on the taskbar.

What methods are available to automatically pin icons to the taskbar when Windows starts?
(PowerShell scripts? registry settings? other configuration?)

enter image description here

JonathanDavidArndt
  • 1,344
  • 7
  • 25
  • 42
  • 1
    Just wanted to point out that hundreds of people (incl. me) have found the solutions for this question to be useful based on the number of likes in one of the replies on this Microsoft post: https://answers.microsoft.com/en-us/windows/forum/all/apps-keep-pinning-themselves-on-startup-to-the/44b0bb7b-575d-4534-aa1c-80258f710514 – takanuva15 Jan 17 '22 at 04:17
  • Oh wow, thank you for sharing that! That is fun and exciting. I am glad I asked this question (and am still pleased with my hastily done free-hand illustration). – JonathanDavidArndt Jan 18 '22 at 15:59

2 Answers2

16

From this documentation: https://docs.microsoft.com/en-us/windows/configuration/configure-windows-10-taskbar

In my case I find: C:\Users\Default\AppData\Local\Microsoft\Windows\Shell\LayoutModification.xml

here i have this line: CustomTaskbarLayoutCollection PinListPlacement="Replace"

-> the items in this PinList will be pinned to the taskbar on every logon (through explorer.exe as far I understand). Even if I remove the items and logon again with same profile the items will be pinned aside manually pinned items.

The part of the xml that defines the StartMenu will only apply on first logon.

mcw
  • 176
  • 2
3

There are a few different ways administrators can accomplish this; the two most common are likely via GPO settings or through a layout modification XML file pushed through GPO.

The local group policy editor has a Start Menu and Taskbar section within User Configuration that has all kinds of options:

You can get really into specifics through the XML method, with a file that looks like this:

<?xml version="1.0" encoding="utf-8"?>
<LayoutModificationTemplate
    xmlns="http://schemas.microsoft.com/Start/2014/LayoutModification"
    xmlns:defaultlayout="http://schemas.microsoft.com/Start/2014/FullDefaultLayout"
    xmlns:start="http://schemas.microsoft.com/Start/2014/StartLayout"
    xmlns:taskbar="http://schemas.microsoft.com/Start/2014/TaskbarLayout"
    Version="1">
  <CustomTaskbarLayoutCollection>
    <defaultlayout:TaskbarLayout>
      <taskbar:TaskbarPinList>
        <taskbar:UWA AppUserModelID="Microsoft.MicrosoftEdge_8wekyb3d8bbwe!MicrosoftEdge" />
        <taskbar:DesktopApp DesktopApplicationLinkPath="%APPDATA%\Microsoft\Windows\Start Menu\Programs\System Tools\File Explorer.lnk" />
      </taskbar:TaskbarPinList>
    </defaultlayout:TaskbarLayout>
 </CustomTaskbarLayoutCollection>
</LayoutModificationTemplate>

Where you can see there is a specific section for <taskbar:TaskbarPinList>.

mael'
  • 1,926
  • 2
  • 10
  • 19
  • This is a good answer, but there may be another way: this is not how our organization has it setup ("Start Layout" group policy for both Local Computer and User are both set to "Not configured") – JonathanDavidArndt Jul 25 '19 at 21:57
  • Replacing both the default user and my current user's LayoutModification.xml files finally stopped the recurring pinning. – AresAvatar Mar 21 '23 at 21:56