WebHostBuilder.UseSetting(String, String) Method

Definition

Add or replace a setting in the configuration.

C#
public Microsoft.AspNetCore.Hosting.IWebHostBuilder UseSetting (string key, string value);
C#
public Microsoft.AspNetCore.Hosting.IWebHostBuilder UseSetting (string key, string? value);

Parameters

key
String

The key of the setting to add or replace.

value
String

The value of the setting to add or replace.

Returns

The IWebHostBuilder.

Implements

Applies to

Produk Versi
ASP.NET Core 1.0, 1.1, 2.0, 2.1, 2.2, 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0