Sounds like this problem.
Try running the "reg add" commands listed in this post.
https://learn.microsoft.com/en-us/answers/questions/1818283/how-to-deploy-kir-through-script
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I am using the following script to update Windows images during Hashicorp Packer builds: https://www.powershellgallery.com/packages/AppVeyorBYOC/1.0.82/Content/hyper-v%5CWindows%5Cscripts%5Cwin-updates.ps1
The script stopped working on Windows 11 22h2 and 23h2 OS versions after installing the KB5040442 update.
I ran a simplified version of the script on my fully updated W11 23H2 laptop to list the details of the already installed updates:
*> $script:UpdateSession = New-Object -ComObject 'Microsoft.Update.Session'
$script:UpdateSearcher = $script:UpdateSession.CreateUpdateSearcher()
$script:SearchResult = New-Object -ComObject 'Microsoft.Update.UpdateColl'
$script:SearchResult = $script:UpdateSearcher.Search("IsInstalled=1 and Type='Software' and IsHidden=0")**
$script:SearchResult.Updates.Count 9**
Write-Host "Update Title is: $($script:SearchResult.Updates.Item(1).Title)"
Update Title is:*
It sees 9 installed software updates, but the title (or any other property) can’t be printed.
Is this a known issue with KB5040442? I saw that there are potential problems with it at https://www.windowslatest.com/2024/07/18/windows-11-kb5040442-issues-update-fails-to-install-causes-other-problems/, but this particular one wasn't among them.
What could I do against this issue?
Sounds like this problem.
Try running the "reg add" commands listed in this post.
https://learn.microsoft.com/en-us/answers/questions/1818283/how-to-deploy-kir-through-script
Hi Norbert Végh,
Thank you for posting in Q&A forum.
First, you could try uninstalling the update and see if that resolves the issue. To do this, go to Settings > Update & Security > Windows Update > View update history > Uninstall updates. Find the update in question and click Uninstall.
If the issue is caused by update KB5040442, it is recommended to provide feedback to Microsoft. You can send feedback using the Feedback Hub app in Windows 10 and 11.Microsoft usually pays attention to user feedback. If a user reports this issue, Microsoft will fix it in a subsequent update.
Please refer to this link.
I hope the information above is helpful.
Best regards
Zunhui
============================================
If the Answer is helpful, please click "Accept Answer" and upvote it.