Skip to content

Commit e0856ec

Browse files
Merge pull request #12556 from ghogen/prefer-32-bit
Explain Prefer 32 bit
2 parents 6f58a91 + ca43569 commit e0856ec

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

docs/ide/how-to-configure-projects-to-target-platforms.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: 'Configure projects to target platforms'
33
description: Set up your applications to target different platforms, including the ARM64 platform in Visual Studio with the Configuration Manager.
4-
ms.date: 11/01/2023
4+
ms.date: 05/06/2024
55
ms.subservice: compile-build
66
ms.topic: how-to
77
helpviewer_keywords:
@@ -49,9 +49,9 @@ For .NET development, .NET 6 or later is required to target the Arm64 platform.
4949

5050
1. On the menu bar, choose **Build** > **Configuration Manager**.
5151

52-
1. In the **Active solution platform** list, choose a platform for the solution to target, and then choose the **Close** button.
52+
1. In the **Active solution platform** list, choose a platform for the solution to target, and then choose the **Close** button.
5353

54-
1. If the platform that you want doesn't appear in the **Active solution platform** list, choose **New**. After you install the tools for a particular platform, you'll be able to add the new solution and project configurations targeting that platform.
54+
1. If the platform that you want doesn't appear in the **Active solution platform** list, choose **New**. After you install the tools for a particular platform, you'll be able to add the new solution and project configurations that target that platform.
5555

5656
The **New Solution Platform** dialog box appears.
5757

@@ -100,6 +100,10 @@ Performing this task varies based on the programming language you're using. See
100100

101101
- For C# projects, see [Build page, Project Designer (C#)](../ide/reference/build-page-project-designer-csharp.md).
102102

103+
### Prefer 32-bit setting
104+
105+
The **Prefer 32-bit** setting in the **Build** page of the project designer for .NET Framework 4.5 or later projects handles the case where you're building the `AnyCPU` configuration, but you want your application to run in 32-bit mode when it's executed on platforms that support both 32-bit and 64-bit modes. If you enable the checkbox, the `PlatformTarget` build property is set to `anycpu32bitpreferred`. See comments on the [PlatformTarget](/dotnet/csharp/language-reference/compiler-options/output#platformtarget) for C# and [/platform](/dotnet/visual-basic/reference/command-line-compiler/platform) for Visual Basic.
106+
103107
### Manually editing the project file
104108

105109
Sometimes, you need to manually edit the project file for some custom configuration. An example is when you have conditions that can't be specified in the IDE, such as a reference that is different for two different platforms, or an assembly that must be registered for a particular platform in order to expose it to COM. The tool that processes the project file is [MSBuild](../msbuild/msbuild.md).

0 commit comments

Comments
 (0)