简体   繁体   English

有什么命令可以显示活动的 Ethe.net 连接名称吗?

[英]Is there any command to display active Ethernet connection name?

I need to display connected Ethe.net name.我需要显示连接的 Ethe.net 名称。

I used the following command to get WLAN connected.network (Wi-Fi).我使用以下命令获取 WLAN connected.network (Wi-Fi)。

C:\Users\User>netsh wlan show interface | findstr /i "SSID"  name
    SSID                   : HOME
    BSSID                  : bc:62:d2:4a:a1:48

Windows 10 网络显示与名称为 HOME 的已连接 Wi-Fi 网络

An error message is output if I run the following command next:如果我接下来运行以下命令,错误消息为 output:

C:\Users\User>netsh lan show interface command

The Wired AutoConfig Service (dot3svc) is not running.

But after I started the service, I still do not get the active connected Ethe.net name.但是在我启动服务后,我仍然没有得到活动连接的 Ethe.net 名称。

C:\Users\User>netsh lan show interface command

There is 1 interface on the system:

    Name             : Ethernet
    Description      : Realtek PCIe GbE Family Controller
    GUID             : e901d916-86f4-4070-9941-47a9a325537a
    Physical Address : 98-E7-43-0F-8F-84
    State            : Connected. Network does not support authentication.

Windows 10 网络显示已连接有线 LAN 网络,名称为 Home

Can anyone help me to get the Ethe.net name Home on wired LAN connection?谁能帮我在有线 LAN 连接上获取 Ethe.net 名称Home

The following command, entered directly in , should display the name of the connected.network profile(s), regardless of whether they are wired or wireless, on a Windows 8 / Server 2012 Operating System or newer.直接在中输入的以下命令应在 Windows 8 / Server 2012 操作系统或更新版本上显示已连接网络配置文件的名称,无论它们是有线还是无线。

For /F Tokens^=6^ Delims^=^" %G In ('%SystemRoot%\System32\wbem\WMIC.exe /NameSpace:\\Root\StandardCimv2 Path MSFT_NetConnectionProfile Where "IPv4Connectivity='4'" Get Name /Format:MOF 2^>NUL') Do @Echo %G

From a , for GUI double-click, it would look a little more like this:中,对于 GUI 双击,它看起来更像这样:

@(For /F Tokens^=6^ Delims^=^" %%G In ('%SystemRoot%\System32\wbem\WMIC.exe
 /NameSpace:\\Root\StandardCimv2 Path MSFT_NetConnectionProfile Where
 "IPv4Connectivity='4'" Get Name /Format:MOF 2^>NUL') Do @Echo %%G) & Pause

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 确定正在使用的以太网接口的命令行 - command line to determine which Ethernet interface is in use 如何随时捕获Windows中命令提示符的显示输出? - How to capture display output from a command prompt in Windows at any moment? 如何从命令 output 中提取/显示任意两列及其值? - How to extract/display any two columns and their values from command output? 有什么方法可以检查哪个显示器是主要显示器,然后在Windows命令行中基于该显示器执行命令? - Is there any way to check which monitor is the primary display, then execute a command based off of that in windows command line? “目录名称无效。”是否有人对解决此命令提示符错误有任何想法? - “The directory name is invalid.” does anybody have any ideas on how to go about fixing this command prompt error? 使用Dir Command,如何在文件名的同一行上显示文件位置? - Using Dir Command, how do I display the file location on the same line as the file name? 如何在命令提示符下更改我的Windows显示用户名? - How can I change my windows display user name in command prompt? 进程名称命令行 - command line of process by name windows命令行:用活动进程打开文件? - windows command line: open file with active process? 如何在命令提示符下获取 LDAP 中的活动连接? - How to get active connections in LDAP in command prompt?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM