I need a script which gives me the information: Does my computer use LAN or WLAN?
Unfortunately “Get-NetAdapter” shows both connections with Status “Up”. How can I extract the currently used connection?
Thanks - Michael
I need a script which gives me the information: Does my computer use LAN or WLAN?
Unfortunately “Get-NetAdapter” shows both connections with Status “Up”. How can I extract the currently used connection?
Thanks - Michael
Depending on your system settings it possible that both connections are activ and used … ![]()
Apparently I can evaluatethe active connection by:
Test-NetConnection -ComputerName <router-ip>
Is this correct? Thanks - Michael
I think it would be helpful if you clarify what “active” means to you. If you want to know what your primary network adapter is, I have a function for that.
Thanks!
In my use case I need to know which network adapter during a procedural backup job from computer to NAS (Drive Snapshot) is used because
Michael
Why don’t you make sure that this backup job only runs on the desired network connection? If it runs as scheduled task you can even set it up in the scheduled task that the task only runs when a specific network connection is available. ![]()
Olaf: Good proposasal but: The jobs runs as a scheduled task for appr. 50 different users with 50 different desired networks. I want to save the effort to maintain the information about the desired network. And: I am kean to know if my assumption “WLAN does not work reliable” is correct.
Michael
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.