diff --git a/Private/Quiet.ps1 b/Private/Quiet.ps1 new file mode 100644 index 0000000..9c9b2b1 --- /dev/null +++ b/Private/Quiet.ps1 @@ -0,0 +1,41 @@ +Function Invoke-Quiet($ComputerName){ + + $QuietPath = "Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\SMS\Client\Client Components\Remote Control" + $CommandStatus = $false + + if(!(Test-Connection -ComputerName $ComputerName -Count 1)) + { + Write-Host "Exiting quiet...No connection made to [$ComputerName]" -ForegroundColor Red + break + } + else + { + $CommandStatus = Invoke-Command -ComputerName $ComputerName -SessionOption (New-PSSessionOption -NoMachineProfile) -ScriptBlock { + + if(Test-Path $Using:QuietPath) + { + Set-ItemProperty -Path $Using:QuietPath -Name "RemCtrl Connection Bar" -Value 0 + Set-ItemProperty -Path $Using:QuietPath -Name "RemCtrl Taskbar Icon" -Value 0 + + Return $true + } + else + { + Return $false + } + + Return $false + } + + if($CommandStatus) + { + Write-Host "Executed quiet override successfully on [$ComputerName] `nPath: $QuietPath" -ForegroundColor Green + } + else + { + Write-Host "Failed quiet override on [$ComputerName]`nPath: $QuietPath`nCheck [$ComputerName] is running Powershell V3.0 or above.`nCheck that registry exists." -ForegroundColor Red + } + } + + Remove-PSSession $ComputerName +} \ No newline at end of file diff --git a/patchnotes.txt b/patchnotes.txt index ca1a4b1..ecdd88b 100644 --- a/patchnotes.txt +++ b/patchnotes.txt @@ -1,3 +1,8 @@ +Patch: 2024-07-15 +-Add UninstallProgram to uninstall a program from the target pc +-Fix Apps to report version and publisher correctly +-Add Quiet to remove the green bar at the top of the screen when using Remote Viewer (-v) + Patch: 2024-07-12 -Refactored SCCM Queries -Fix Get-PC now accepts IP addresses and MAC addresses along with asset tags and service tags