From 4da69842a08d155deba2664fb5b3760f396b2b94 Mon Sep 17 00:00:00 2001 From: Gabe Date: Sat, 9 Aug 2025 17:10:51 +0000 Subject: [PATCH] Upload files to "Fun\Random" --- .../Interactive Prompt to Uninstall a Program.ps1" | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 "Fun\\Random/Interactive Prompt to Uninstall a Program.ps1" diff --git "a/Fun\\Random/Interactive Prompt to Uninstall a Program.ps1" "b/Fun\\Random/Interactive Prompt to Uninstall a Program.ps1" new file mode 100644 index 0000000..c6c379a --- /dev/null +++ "b/Fun\\Random/Interactive Prompt to Uninstall a Program.ps1" @@ -0,0 +1,8 @@ +Get-WmiObject -Class Win32_Product | Select-Object -Property Name | Out-GridView + +[void][System.Reflection.Assembly]::LoadWithPartialName('Microsoft.VisualBasic') +$Program = [Microsoft.VisualBasic.Interaction]::InputBox('Please enter the name of the program you wish to uninstall', 'Uninstall Program') + +$MyApp = Get-WmiObject -Class Win32_Product | Where-Object { $_.Name -eq "$Program" } + +$MyApp.Uninstall() \ No newline at end of file