Security Incident Response

If you think you have or know you have a Security Incident please fill in the form and our experienced Onevinn CSIRT team will reach out shortly.
The team has long experience in supporting customers in Incident Response and Compromised Recovery.
Keep calm and we will be with you shortly!

Jörgen Nilsson 19 Oct 2021
1 min

Modify Windows 11 Taskbar during OSD, Intune and GPO

When it comes to modifying the TaskBar in Windows 11 nothing has changed since Windows 10. The only change is that the Start Menu part of the XML file is no longer used, it has been replaced by a .json file. More on that in the next post. More information can be found here on Microsoft Docs: Configure and customize Windows 11 taskbar – Configure Windows | Microsoft Docs
What do we need to modify the TaskBar then? We need an .XML file as shown below as sample. It will remove everything and replace it with Edge and File Explorer.

Sample .XML file

<?xml version="1.0" encoding="utf-8"?>
  <CustomTaskbarLayoutCollection PinListPlacement="Replace">
        <taskbar:DesktopApp DesktopApplicationID="MSEdge"/>
        <taskbar:DesktopApp DesktopApplicationID="Microsoft.Windows.Explorer"/>

If we want to keep the default and only add pinned apps to the TaskBar, we remove the PinListPlacement=”Replace” from the XML file.

Modify Windows 11 Taskbar during OSD

We can use the same script as we did in Windows 10 to import a default start menu layout during OSD. I have mine in a folder called Windows 11 Taskbar which contains my Taskbar.xml file and a PowerShell script to import it. This script will import it during OSD as a default Taskbar that the end user can change as they want.

The PowerShell script consist of one-line, which will import the Taskbar.xml file during OS deployment.

Import-StartLayout -LayoutPath $PSScriptRoot\Startmenustd.xml -MountPath $env:SystemDrive\

My Task Sequence contains the following step which I have added to my “Windows 11 Customization” group with a condition to only apply on “Windows 11 64-bit”

Modify Windows 11 Taskbar using Intune

In Intune we can deploy a Custom Taskbar layout using the same Configuration Profile we did for the Start Menu layout in Windows 10. The policy must be applied before the end-user logs on for the first time.

  • Create a new Configuration Policy,
  • Under the Start section, import the .xml file you want to use.

Modify Windows 11 Taskbar using Group Policy

Deploying a custom Taskbar using Group Policy can be done using the “Start Layout” policy we used for Windows 10 to import Taskbar and Start Menu layout. It still works for the Taskbar part. Place the .xml file on a share so it is reachable for the client.

In the Group Policy we point to our “taskbar.xml” file we want the computer to use.

If the Group Policy is applied to a computer that is already deployed it will overwrite the change the end user have done to the Taskbar on the next logon.