C# 为什么我能';在我的Windows 10计算机中不使用HttpListener?(系统平台不支持异常)

C# 为什么我能';在我的Windows 10计算机中不使用HttpListener?(系统平台不支持异常),c#,windows,C#,Windows,这对我不起作用 Console.WriteLine(System.Net.HttpListener.IsSupported); // false 代码: 错误: System.PlatformNotSupportedException: Operation is not supported on this platform In System.Net.HttpListener..ctor() 我最近重新安装了Windows101703,我不知道为什么会这样 但我可以在Windows 10

这对我不起作用

Console.WriteLine(System.Net.HttpListener.IsSupported); // false
代码:

错误:

System.PlatformNotSupportedException: Operation is not supported on this platform

In System.Net.HttpListener..ctor()
我最近重新安装了Windows101703,我不知道为什么会这样

但我可以在Windows 10 1511上使用它

它帮助了我

因为我的HTTP开始选项是4

我修好了

sc config http start=demand
sc start http

可能是重复的不,这帮不了我。真是晦涩难懂。你可能会认为这是Windows10中一个突破性变化的基础,异常消息会说一些有意义的话。
sc config http start=demand
sc start http