Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Invoking the WiFi connections UI in Windows 10

Prior to Windows 10, the WiFi connections UI could be invoked via a ShellExecute using the appropriate GUIDs/strings, details of which can be fairly easily found on the web. This changed in Windows 10. Although there is an API which can be used to programmatically manage WiFi connections (Native WiFi), and there is even a C# wrapper for it on CodePlex, I'd have to build my own UI around it; I can't find any information on how to launch the existing Windows 10 UI for managing WiFi connections. I'd rather not have to build my own duplicate of functionality which already exists just because the existing functionality can't be invoked programmatically.

Is it not publicly exposed? If it is callable, how is it done? Is it just a different ShellExecute?

like image 990
C Robinson Avatar asked Sep 01 '25 16:09

C Robinson


2 Answers

You could try running the command "%windir%\explorer.exe ms-availablenetworks:" . Alternatively, "Start ms-availablenetworks:" in command prompt.

I came across this on another post and seems like it should do what you're looking for. It hasn't worked for me but perhaps you'd have better luck.

There's plenty of other URIs available too. Here's the list I found: https://www.tenforums.com/tutorials/78108-app-commands-list-windows-10-a.html

like image 126
GroomedGorilla Avatar answered Sep 07 '25 23:09

GroomedGorilla


The Uri for the available networks is ms-availablenetworks:

So just use this in your code:

var success = await Windows.System.Launcher.LaunchUriAsync(new Uri(@"ms-availablenetworks:"));

like image 39
Rui Ying Avatar answered Sep 07 '25 23:09

Rui Ying