The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,482 other followers

Windows <= 10: batch file to open Windows Update panel

Posted by jpluimers on 2019/02/15

Up until Widows 8.1, you could use wuapp to start the Windows Update panel.

For a while, Windows 10 needed a cumbersome language specific workaround described at Windows 10 – language neutral batch file to start Windows.

That stopped working after a few builds, but I forgot to make a note in which build exactly. Already in Windows 10 build 10122, the icon in wucltux.dll, so this might have been shortly after the initial “RTM” (retroactively named 1507).

So for a while, I had this batch file:

Since then I had to maintain too many locales running Windows 10. So here is the batch file:

for /f "delims=" %%A in ('PowerShell -Command "(Get-Culture).Name"') do explorer "%LocalAppData%\Packages\windows.immersivecontrolpanel_cw5n1h2txyewy\LocalState\Indexed\Settings\%%A\AAA_SystemSettings_MusUpdate_UpdateActionButton.settingcontent-ms"

It uses these tricks:

  1. Set output of a command as a variable (in this case a for loop variable)
  2. Execute PowerShell script in a .bat file
  3. PowerShell Get-Culture (which gets a .NET CultureInfo instance)
  4. CultureInfo.Name property (which has the nl-NL, en-US, etc codes in it)

But now I have extended it to support old and new Windows versions:

if exist %windir%\System32\wuapp.exe (
  %windir%\System32\rundll32.exe url.dll,FileProtocolHandler wuapp.exe
) else (
  %windir%\explorer ms-settings:windowsupdate


via: Windows Update Shortcut – Create in Windows 10 – Windows 10 Forums

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: