question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Release Build Error with NavigationView

See original GitHub issue

Describe the bug When I create a project with a NavigationView and start the package in den the debug configuration everything works fine, but if I start it with the release configuration I get a Cannot find a Resource with the Name/Key TabViewButtonBackground error message.

Steps to reproduce the bug

Steps to reproduce the behavior:

  1. Create a blank WinUi desktop project with package
  2. Delete the button from the xaml and cs
  3. Add a simple NavigationView to the xaml
  4. Build and start the app in release configuration

Expected behavior App works the same as in debug configuration

Version Info

  • Nuget WinUI: 3.0.0-preview2.200713.0
  • .net SDK: 5.0.100-preview.5.20279.10 (x86 and x64)
  • VS: 16.7.0 Preview 4.0 (4.8.04084)
  • Windows: Win10 19041

NuGet package version: [Microsoft.WinUI 3.0.0-preview2.200713.0]

Windows 10 version Saw the problem?
Insider Build (xxxxx) not tested
May 2020 Update (19041) Yes
November 2019 Update (18363) not tested
May 2019 Update (18362) not tested
October 2018 Update (17763) not tested
April 2018 Update (17134) not tested
Fall Creators Update (16299) not tested
Creators Update (15063) not tested
Device form factor Saw the problem?
Desktop Yes
Xbox not tested
Surface Hub not tested
IoT not tested

Additional context I found the following Issue 1295 which sounded similar enough but the fix did not work. A simple Test project with all the described reproduce steps App1.zip

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
stevenbrixcommented, Aug 27, 2020

@icnocop this sounds somewhat familiar, can you try adding this to your project file:

<PropertyGroup>
   <DisableEmbeddedXbf>true</DisableEmbeddedXbf>
</PropertyGroup>
0reactions
icnocopcommented, Aug 27, 2020

Thank you, @stevenbrix!

That worked! 🎉

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error inflating in NavigationView - android
My App is crashing when android tries to open this activity containing Navigation Drawer.I develop same type of app before but this never ......
Read more >
error build: Cannot find 'NavigationStack' in scope
i have MACOS 11.6.2 and my xcode version is 13.2.1 and i am getting this same error "Cannot find 'NavigationStack' in scope" how...
Read more >
Navigation | Jetpack
Version 2.6.0-rc02 contains these commits. Bug Fixes. Fixed an issue with Navigation in Fragments where navigating with popUpTo and popping a fragment off...
Read more >
Stable channel release notes for the Windows App SDK
Provides information about the stable release channel for the Windows App SDK.
Read more >
NavigationView - Windows apps
NavigationView is an adaptive navigation control that works well for: Providing a consistent navigational experience throughout your app.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found