Jump to content

Recommended Posts

Posted

I want to uninstall the Windows 11 widgets via autoit and powershell.

This is the code for powershell

winget uninstall --id 9MSSGKG348SP

Normally I know how to run a powershell command with autoit.

But in this case the window will ask me if I want to continue or not and I have to type Y or N. 

How to handle such type of interaction with powershell?

  • Developers
Posted

Doesn't the silent option do what you want?

Quote
Options:

   --accept-source-agreements   Accept the source license agreement, and avoid the prompt.
   -e, --exact    Use the exact string in the query, including checking for case-sensitivity.
                  It will not use the default behavior of a substring.

   -h, --silent   Run the uninstaller in silent mode. This suppresses all UI.
                  The default experience shows uninstaller progress.

 

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted
--accept-source-agreements 

Helps a lot, but I used it in the powershell and typed the command. 

I have to do another test with the script on a new win 11 installation.

But I think it will work, thanks a lot for the fast reply. 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...