0

Trying to change what OS my TS supports in order to hide/show it in Software Center.

Importing ConfigurationManager.psd1 module and according to documentation for Set-CMTaskSequence I should be able to specify which OS that should be supported:

enter image description here

If I manually set a specific OS and then want to undo following code change my TS back to "Run on any platform":

Set-CMTaskSequence -TaskSequenceId XYZ00023 -RunOnAnyPlatform

The code i'm currently trying to set specified OS gives error:

enter image description here

Set-CMTaskSequence -TaskSequenceId XYZ00023 -AddSupportedOperatingSystemPlatform (Get-CMSupportedPlatform | Where-Object {$_.CI_UniqueID -eq 'Windows/All_x64_Windows_8.1'})

It doesn't mather which OS I'm trying to set same error occur everytime.

Anyone tried and successfully changed this value using Powershell and can assist in how to?

mhu
  • 17,720
  • 10
  • 62
  • 93
  • Using `-Verbose` a warning is shown: `WARNING: Unsupported platform 'All x64 Windows 8.1 devices' for task sequence.` – mhu Feb 14 '22 at 11:23
  • Indeed I get that warning too. As shown in my post. I did mention that this is shown no mather what OS I try to set. Clearly something not working configuring the value as I do. Thats why I asked for help. – Markus Sacramento Feb 14 '22 at 11:56

1 Answers1

1

If you use -Verbose a warning is shown: WARNING: Unsupported platform 'All x64 Windows 8.1 devices' for task sequence.

Found the solution here: https://blog.adexis.com.au/2019/06/14/sccm-windows-10-no-longer-ticked-as-deployment-target-os-for-packages-and-tss-after-upgrade-to-current-branch/

You should use the OS denoted with client:

$os = Get-CMSupportedPlatform -Fast | Where-Object { $_.CI_UniqueID -eq "Windows/All_x64_Windows_8.1_Client" }
Set-CMTaskSequence -TaskSequenceName "XYZ00023" -AddSupportedOperatingSystemPlatform $os -Verbose
mhu
  • 17,720
  • 10
  • 62
  • 93