+ ?(gwmi -computer $usrinpcn Win32_Product -filter "Name LIKE '%$usrinpsw%'").Uni. You cannot call a method on a null-valued expression.Īt C:\ITtools\New Text Document.ps1:7 char:2 PS C:\ITtools> C:\ITtools\New Text Document.ps1Įnter The computer you would like to uninstall from: mypc01Įnter the software you would like to ininstall: VLC I get the error below when I try your script (gwmi -computer $usrinpcn Win32_Product -filter "Name LIKE '%$usrinpsw%'").Uninstall() $usrinpsw = read-host "Enter the software you would like to ininstall" $usrinpcn = read-host "Enter The computer you would like to uninstall from" Write-host "This will remoteley uninstal software" Here is a little powershell script that can help I used this to uninstall quicktime from computers If you're confident that no other files match the search masks then you can of course use FileDelete() instead. Requires the Flash Uninstaller, which you can get from Adobe. If $result=0 then msgbox(16,'fail',$thisdll)ĪutoIt code, of course. $result=filemove($thisdll,'*_disabled.txt',1) $runstr='cmd /c dir /b /s ' & $basedir & $dllmask & ' >' & /c dir /b /s ' & $basedir & $ocxmask & ' >' & /c dir /b /s ' & $basedir & $setupmask & ' >' & then exit Text & & '\uninstall_flash_player -uninstall'
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |