【发布时间】:2015-08-27 13:01:07
【问题描述】:
我试图弄清楚如何确定活动网络何时是公共的。有没有办法通过 WMIC 或 CMD 提示来实际显示“公共”作为状态? netstat 似乎没有给我我想要的东西,IPconfig 没有显示“公共”。我在 Powershell 中尝试了 Get-NetConnectionProfile,但没有运气:(
“Get-NetConnectionProfile”一词未被识别为 cmdlet、函数、脚本文件或可运行程序的名称。检查名称的拼写,如果包含路径,请验证路径是否正确,然后重试。
在 line:1 char:25
- 获取网络连接配置文件
- CategoryInfo : ObjectNotFound: (Get-NetConnectionProfile:String) [], CommandNotFoundException
- FullyQualifiedErrorId:CommandNotFoundException
有什么想法吗?
【问题讨论】:
-
我在 Powershell 中尝试了 Get-NetConnectionProfile,但没有成功:(您遇到了什么具体问题?
-
Get-NetConnectionProfile :术语“Get-NetConnectionProfile”未被识别为 cmdlet、函数、脚本文件或可运行程序的名称。检查名称的拼写,或者如果包含路径,请验证路径是否正确并重试。在 line:1 char:1 + Get-NetConnectionProfile + ~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : ObjectNotFound: (Get-NetConnectionProfile:String) [] , CommandNotFoundException + FullyQualifiedErrorId : CommandNotFoundException
-
操作系统? PowerShell 版本?
-
Win 7 64,Powershell ISE v1.0
标签: cmd