Skip to content

Problem when PlatformTarget is omitted from .csproj #5901

@vsfeedback

Description

@vsfeedback

This issue has a corresponding ticket on Developer Community. Please vote and comment there to make sure your voice is heard.


This is a problem when using .NET Framework with .csproj in SDK-style.

If you omit <PlatformTarget>, the target platform will be displayed as "x86" in the GUI project settings, but it will be executed in 64bit.

I think "AnyCPU" is the correct.

<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>net472</TargetFramework>
  </PropertyGroup>

</Project>
  • Windows 10 64bit
  • Visual Studio Community 2019 Version 16.4.4

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions