Cannot locate resource 'mainwindow.xaml'
- Dominant language
- C#
- Stars
- 7.7k
- Forks
- 1.3k
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 61
Description
_This issue has been moved from [a ticket on Developer Community](https://developercommunity.visualstudio.com/t/Cannot-locate-resource-mainwindowxaml/10238138)._
---
[severity:It bothers me. A fix would be nice]
WPF causing System.IO.IOException on startup when:
1. *.csproj indicate `en-US`
2. AssemblyInfo.cs indicate `[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.MainAssembly)]` (only when `location` is `MainAssembly`, i.e. no problem when `location` is `satellite`)
Encountered on .NET Framework 4.7.2.
Problem disappeared after `UICulture` was removed.
---
### Original Comments
#### Feedback Bot on 12/26/2022, 08:09 AM:
(private comment, text removed)
#### Nina Wang [MSFT] on 12/26/2022, 00:55 PM:
(private comment, text removed)
#### brandonstudio on 12/28/2022, 05:37 AM:
(private comment, text removed)
#### Nina Wang [MSFT] on 12/28/2022, 08:21 AM:
(private comment, text removed)
#### Feedback Bot on 12/28/2022, 08:22 AM:
(private comment, text removed)
#### Feedback Bot on 2/7/2023, 05:46 PM:
(private comment, text removed)
---
### Original Solutions
(no solutions)
### Sample Repro
[ResourceLocalizationIssue.zip](https://github.com/dotnet/wpf/files/10836831/ResourceLocalizationIssue.zip)
Edit - Adding sample repro
Contributor guide
Assessment
This issue has not been assessed yet.