Forum Discussion
Company Portal Installation failing due to missing Microsoft.UI.Xaml.2.7
Hi Bogdan_Guinea
We setup device using Autopilot . Join Type is "Microsoft Entra hybrid joined". In ESP we did not select any apps to be installed during Autopilot process. In ESP we have set "Block device use until all apps and profiles are installed" is set to No.
We deploy below 2 Microsoft Store app (new) as required assignments.
1. Microsoft 365 Copilot.
2. Microsoft Company Portal.
Since we can't set the App Installation Order. So i can't say if Company Portal is 1st App that will be installed or not.
Hi, you didn't answer me regarding which OS versions this is happening on?
So, no Win32 package as I can see right now...
At this point, you don't have many options. Deploying a platform script will take precedence over app installation in your case (Copilot and Company Portal). In theory, this could work. The problem is (that's why I asked about OS versions): winget is embedded only in Windows 11 and not on all Windows 10 versions.
The second option is calling NuGet directly in a script, but based on your firewall/proxy, I'm not sure if it will go through.
The Fallback Block Only in your case (from lines 15 to 35) should work. I compiled it, ran it myself, and it worked fine on a Windows 11 with no Company Portal.
Good luck!
# Standalone Microsoft.UI.Xaml.2.7 installer - downloads + installs
# Run as SYSTEM (Intune script) or Admin
# If Winget Present - Use it otherweise fallback to NuGet download + install
try {
$wingetPath = (Get-ChildItem "C:\Program Files\WindowsApps\Microsoft.DesktopAppInstaller_*_x64__8wekyb3d8bbwe" | Sort-Object LastWriteTime -Descending | Select-Object -First 1).FullName
if ($wingetPath) {
& "$wingetPath\winget.exe" install --id 9P5VK8KZB5QZ --exact --silent --accept-source-agreements --scope machine --force
Start-Sleep 3
}
} catch {
Write-Output "Winget not available, trying NuGet method..."
}
# Fallback - Direct NuGet download + install
$nugetUrl = "https://www.nuget.org/api/v2/package/Microsoft.UI.Xaml/2.7.3"
$zipFile = "$env:TEMP\xaml27.zip"
try {
Invoke-WebRequest -Uri $nugetUrl -OutFile $zipFile -UseBasicParsing
Expand-Archive -Path $zipFile -DestinationPath "$env:TEMP\xaml27" -Force
# Install
$appx64 = "$env:TEMP\xaml27\tools\AppX\x64\Release\Microsoft.UI.Xaml.2.7.appx"
if (Test-Path $appx64) {
Add-AppxPackage -Path $appx64 -ErrorAction SilentlyContinue | Out-Null
Write-Output "UI.Xaml x64 installed"
}
# Cleanup
Remove-Item "$env:TEMP\xaml27" -Recurse -Force -ErrorAction SilentlyContinue
Remove-Item $zipFile -Force -ErrorAction SilentlyContinue
} catch {
Write-Warning "NuGet method failed: $_"
}
# Verify
<# $pkg = Get-AppxPackage -Name "Microsoft.UI.Xaml.2.7" -AllUsers -ErrorAction SilentlyContinue
if ($pkg) {
Write-Output "SUCCESS: Microsoft.UI.Xaml.2.7 v$($pkg.Version) installed"
exit 0
} else {
Write-Error "FAILED: Microsoft.UI.Xaml.2.7 not found after install"
exit 1
}
#>
- Sriram_JastiJan 14, 2026Copper Contributor
Hi Bogdan_Guinea
I will check and get back to you regarding the OS version.
Thank you for sharing the script. I have Noted on the Platform Script option.
In order to fix on existing devices. Can i use the above script in Remediations ? If yes, Lines 37 to 46 can be used as detection script ?- Bogdan_GuineaJan 15, 2026Steel Contributor
Hi,
Yes, you can use these lines as detection logic for already provisioned or onboarded devices. For remediation, use either Winget or NuGet to determine which works, and add corresponding exit codes in the remediation blocks—for example, add "exit 0" after line 27 and "exit 1" after line 34 if using the NuGet method.
Good luck!
- Sriram_JastiJan 30, 2026Copper Contributor
Hi Bogdan_Guinea
In the last days i setup some Windows 11 Version 25H2 devices and on these device i am experiencing the problem i explained in this article. I have to wait sometimes 2 days, restart and sync device multiple times to get Company Portal Installed Successfully.
In the Eventviewer Logs location (Microsoft-Windows-AppXDeploymentServer/Operational) I see below errors.
OnDemandRegisterPackage Microsoft.UI.Xaml.2.7_7.2409.9001.0_x64__8wekyb3d8bbwe, unable to find the package from StateRepository, we will register it later.AppX deployment operation failed for package Microsoft.StartExperiencesApp_2021.151.0.0_neutral_~_8wekyb3d8bbwe with error 0x80073CF3.The specific error text for this failure is: The package Microsoft.StartExperiencesApp_1.151.0.0_x64__8wekyb3d8bbwe cannot be installed because this package depends on a framework that was not found.Provide the framework published by “Microsoft.WindowsAppRuntime.1.6” “CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US” with neutral or x64 processor architecture and at least version 6000.424.1611.0 together with this package to be installed.
Windows cannot install package Microsoft.StartExperiencesApp_1.151.0.0_x64__8wekyb3d8bbwe because this package depends on a framework that could not be found. Provide the framework "Microsoft.WindowsAppRuntime.1.6" published by "CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US", with neutral or x64 processor architecture and minimum version 6000.424.1611.0, along with this package to install.