Skip to content

Commit

Permalink
Merge pull request #10452 from MicrosoftDocs/main638652422875908830sy…
Browse files Browse the repository at this point in the history
…nc_temp

For protected branch, push strategy should use PR and merge to target branch method to work around git push error
  • Loading branch information
learn-build-service-prod[bot] authored Oct 23, 2024
2 parents a7b4a27 + 7b3f2be commit 56410ec
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 18 deletions.
2 changes: 1 addition & 1 deletion docs/debugger/using-the-debuggerdisplay-attribute.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ ms.subservice: debug-diagnostics
---
# Tell the debugger what to show using the DebuggerDisplay Attribute (C#, Visual Basic, F#, C++/CLI)

The <xref:System.Diagnostics.DebuggerDisplayAttribute> controls how an object, property, or field is displayed in the debugger variable windows. This attribute can be applied to types (classes, structs, enums, delegates). If applied to a base type, the attribute also applies to a subclass.
The <xref:System.Diagnostics.DebuggerDisplayAttribute> controls how an object, property, or field is displayed in the debugger variable windows. This attribute can be applied to types (classes, structs, enums, delegates), but is typically applied only to classes and structs. If applied to a base type, the attribute also applies to a subclass.

The `DebuggerDisplay` attribute has a single argument, which is a string to be displayed in the value column for instances of the type. This string can contain braces (`{` and `}`). Text within a pair of braces is evaluated as a field, property or method.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ You can configure the ClickOnce trust prompt to control whether end users are gi
|Option|Registry setting value|Description|
|------------|----------------------------|-----------------|
|Enable the trust prompt.|`Enabled`|The ClickOnce trust prompt is displayed so that end users can grant trust to ClickOnce applications.|
|Restrict the trust prompt.|`AuthenticodeRequired`|The ClickOnce trust prompt is only displayed if ClickOnce applications are signed with a certificate that identifies the publisher.|
|Disable the trust prompt.|`Disabled`|The ClickOnce trust prompt is not displayed for any ClickOnce applications that are not signed with an explicitly trusted certificate.|
|Restrict the trust prompt.|`AuthenticodeRequired`|The ClickOnce trust prompt is only displayed if ClickOnce applications are signed with a certificate that identifies the publisher. Otherwise, the ClickOnce application won't be installed.|
|Disable the trust prompt.|`Disabled`|The ClickOnce trust prompt isn't displayed. Only ClickOnce applications that are signed with an explicitly trusted certificate will be installed.|

The following table shows the default behavior for each zone. The Applications column refers to Windows Forms applications, Windows Presentation Foundation applications, WPF browser applications, and console applications.

Expand Down Expand Up @@ -57,9 +57,9 @@ You can configure the ClickOnce trust prompt to control whether end users are gi

**\HKEY_LOCAL_MACHINE\SOFTWARE\MICROSOFT\\.NETFramework\Security\TrustManager\PromptingLevel**

If the key does not exist, create it.
If the key doesn't exist, create it.

3. Add the following subkeys as **String Value**, if they do not already exist, with the associated values shown in the following table.
3. Add the following subkeys as **String Value**, if they don't already exist, with the associated values shown in the following table.

|String Value subkey|Value|
|-------------------------|-----------|
Expand Down Expand Up @@ -119,9 +119,9 @@ You can configure the ClickOnce trust prompt to control whether end users are gi

**\HKEY_LOCAL_MACHINE\SOFTWARE\MICROSOFT\\.NETFramework\Security\TrustManager\PromptingLevel**

If the key does not exist, create it.
If the key doesn't exist, create it.

3. Add the following subkeys as **String Value**, if they do not already exist, with the associated values shown in the following table.
3. Add the following subkeys as **String Value**, if they don't already exist, with the associated values shown in the following table.

|String Value subkey|Value|
|-------------------------|-----------|
Expand Down Expand Up @@ -165,7 +165,7 @@ You can configure the ClickOnce trust prompt to control whether end users are gi
3. Build and run the application.

## Disable the ClickOnce trust prompt
You can disable the trust prompt so that end users are not given the option to install solutions that are not already trusted in their security policy.
You can disable the trust prompt so that end users aren't given the option to install solutions that aren't already trusted in their security policy.

#### To disable the ClickOnce trust prompt by using the registry editor

Expand All @@ -179,9 +179,9 @@ You can configure the ClickOnce trust prompt to control whether end users are gi

**\HKEY_LOCAL_MACHINE\SOFTWARE\MICROSOFT\\.NETFramework\Security\TrustManager\PromptingLevel**

If the key does not exist, create it.
If the key doesn't exist, create it.

3. Add the following subkeys as **String Value**, if they do not already exist, with the associated values shown in the following table.
3. Add the following subkeys as **String Value**, if they don't already exist, with the associated values shown in the following table.

|String Value subkey|Value|
|-------------------------|-----------|
Expand Down
12 changes: 4 additions & 8 deletions docs/get-started/csharp/tutorial-console-part-2.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: "Tutorial 2: Extend your C# console app"
description: Extend a C# console application in Visual Studio, including debugging features, managing multiple projects, and referencing third-party packages.
ms.custom: vs-acquisition
ms.date: 09/05/2024
ms.date: 10/18/2024
ms.subservice: general-ide
ms.topic: tutorial
ms.devlang: csharp
Expand Down Expand Up @@ -232,14 +232,10 @@ In Visual Studio, you use the menu command **File** > **Add** > **New Project**
using CalculatorLibrary;
```

Adding the `using` directive should let you remove the `CalculatorLibrary` namespace from the call site, but now there's an ambiguity. Is `Calculator` the class in `CalculatorLibrary`, or is `Calculator` the namespace?

To resolve the ambiguity, rename the namespace from `Calculator` to `CalculatorProgram` in *Program.cs*.
Adding the `using` directive should let you remove the `CalculatorLibrary` namespace from the call site.

```csharp
// Program.cs
namespace CalculatorProgram
```
If your `Program.cs` code is in the `Calculator` namespace, rename the namespace from `Calculator` to `CalculatorProgram` to remove ambiguity between class name and namespace name.

::: moniker-end

## Reference .NET libraries: Write to a log
Expand Down

0 comments on commit 56410ec

Please sign in to comment.