-
Notifications
You must be signed in to change notification settings - Fork 62
Description
What happened?
We are attempting to migrate to the WebView2 composition control from the standard WebVew2 control and are getting the following runtime error:
System.IO.FileNotFoundException: 'Could not load file or assembly 'Microsoft.Windows.SDK.NET, Version=10.0.17763.10, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified.'
This is from simply replacing occurrences of WebView2 with WebView2CompositionControl in both the XAML and Code. It seems the composition control has some specific dependency which we are not satisfying, however I am not sure how to resolve it.
Our project property groups looks like this:
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows</TargetFramework>
<Nullable>enable</Nullable>
<UseWindowsForms>True</UseWindowsForms>
<UseWPF>true</UseWPF>
<EnableDefaultApplicationDefinition>false</EnableDefaultApplicationDefinition>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<RootNamespace>XXX</RootNamespace>
<AssemblyName>XXX</AssemblyName>
<ApplicationIcon>Resources\favicon.ico</ApplicationIcon>
<Description>XXXX</Description>
<PackageProjectUrl>XXXX</PackageProjectUrl>
<Platforms>AnyCPU;x64</Platforms>
<ApplicationManifest>app.manifest</ApplicationManifest>
<UseRidGraph>true</UseRidGraph>
<!--<SupportedOSPlatformVersion>10.0.26100.0</SupportedOSPlatformVersion>-->
</PropertyGroup>
Importance
Important. My app's user experience is significantly compromised.
Runtime Channel
Stable release (WebView2 Runtime), Prerelease (Edge Canary/Dev/Beta)
Runtime Version
No response
SDK Version
1.0.3405.78
Framework
WPF
Operating System
Windows 11
OS Version
26100.4946
Repro steps
Replace occurrences of WebView2 to WebView2CompositionControl in XAML and Code behind.
Repros in Edge Browser
No, issue does not reproduce in the corresponding Edge version
Regression
No, this never worked
Last working version (if regression)
No response