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.

[Bug] Unable to run maui or maui-blazor template WinUI option from Visual Studio

See original GitHub issue

Description

I create the template, open VS2022, run the WinUI option, and I see an error.

Steps to Reproduce

  1. dotnet new maui-blazor -n MauiBlzor
  2. Open VS2022 and open the MauiBlzor project.
  3. Select the MauiBlzor entry and debug/run it.
  4. Observe that it fails due to “target Run does not exist for the project”.

Expected Behavior

Not this. A window should open and show some ui like for the Android emulated version.

Actual Behavior

msbuild process errors.

Basic Information

  • Version with issue: Fresh VS2022 preview 7 install with all extra MAUI bits.
  • Last known good version: Never run it.
  • IDE: VS2022 preview 7
  • Platform Target Frameworks:
    • iOS:
    • Android:
    • UWP:
  • Android Support Library Version:
  • Nuget Packages:
  • Affected Devices:

Screenshots

maui-vs2022

Reproduction Link

See the steps above.

Workaround

There is another issue on maui-samples talking about using --no-restore but that is on the command-line, and does not apply here as there is no place for me to put it in the VS2022 UI that I understand.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:3
  • Comments:24 (15 by maintainers)

github_iconTop GitHub Comments

7reactions
rt121212121commented, Aug 16, 2021

This is what happens when I set that as startup and debug it.

image

6reactions
Eiloncommented, Aug 17, 2021

@rt121212121 yup, understood, this is definitely a frustrating issue right now but I just heard there is a fix for this coming soon.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshoot known issues - .NET MAUI
The solution to this issue on Windows is to uninstall the .NET MAUI workloads through the CLI, uninstall any .NET SDKs in Control...
Read more >
Visual Studio 2022 preview 6 MAUI projects loading problem
Microsoft Visual Studio Community 2022 (64-bit) - Preview Version 17.1.0 Preview 6.0 is not loading MAUI Blazor project, which was loading in Preview...
Read more >
Creating new .NET 6 MAUI project
I want to work with MAUI and therefore installed all the necessary stuff (partwise using maui-check).
Read more >
Blazor Hybrid Web Apps with .NET MAUI
NET MAUI Blazor app is created using the MAUI-Blazor template. From Visual Studio, this is as simple as choosing the template from the...
Read more >
Is Maui dead on arrival? : r/dotnet
Since I want to be able to develop something for multiple platforms including webassembly, MAUI + Blazor seems to be the only option...
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