2
私は自分自身にasp .netコアを教えています。私はgetting started guideに行きます。名前 'HtmlEncoder'は現在のコンテキストに存在しません
public string Welcome(string name, int numTimes = 1)
{
return HtmlEncoder.Default.Encode($"Hello {name}, numTimes: {numTimes}");
}
しかし、私はエラーを取得しています:
Severity Code Description Project File Line Suppression State
Error CS0103 The name 'HtmlEncoder' does not exist in the current context TestApp..NETCoreApp,Version=v1.0 c:\Users\administrator\documents\visual studio 2015\Projects\TestApp\src\TestApp\Controllers\HelloWorldController.cs 23 Active
は私が間違って何をしました私のHelloWorldControllerでは、私はこの方法がありますか?