maui
maui copied to clipboard
Visual Studio 2022 17.4 Preview 1, Maui projects with only 1 Target do not work
Description
After upgrading to Visual Studio 2022 17.4 Preview 1, Maui projects with only 1 Target do not work.

Steps to Reproduce
.csproj
<PropertyGroup>
<TargetFrameworks>net6.0-android</TargetFrameworks>
<OutputType>Exe</OutputType>
<RootNamespace>MauiApp13</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>
<!-- Display name -->
<ApplicationTitle>MauiApp13</ApplicationTitle>
<!-- App Identifier -->
<ApplicationId>com.companyname.mauiapp13</ApplicationId>
<ApplicationIdGuid>3827a0ba-0bbe-4661-ab46-68547eee3c73</ApplicationIdGuid>
<!-- Versions -->
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">23.0</SupportedOSPlatformVersion>
</PropertyGroup>
Version with bug
6.0.486 (current)
remove the s, so only use TargetFramework. Does this work?
@MagicAndre1981 That was the first thing I tried. Does not work ;(
Have you tried setting the debug profile to the Android emulator instead of Windows? You can't target Android in the project file but then use Windows as the Visual Studio debug target.
Thanks for the issue report @pierrebrito! This issue appears to be a problem with Visual Studio, so we ask that you use the VS feedback tool to report the issue. That way it will get to the routed to the team that owns this experience in VS.
If you encounter a problem with Visual Studio, we want to know about it so that we can diagnose and fix it. By using the Report a Problem tool, you can collect detailed information about the problem, and send it to Microsoft with just a few button clicks.
- Go to the VS feedback tool to report the issue
- Close this bug, and consider adding a link to the VS Feedback issue so that others can follow its activity there.
This issue will be automatically closed in 3 days if there are no further comments.