

You can use the below script for the RSAT install effort via the task.You can write a separate script to create the scheduled task.So, could be considered off-topic for Stackoverflow and more a question for SuperUser or StackExchange.Īll that being said, you can still use PowerShell to do this, but doing so by using PowerShell to set a scheduled task to the targets and set that to the admin creds at run once at login. It's specifically how do I use GPO to enable a Windows feature or install software, using PowerShell? Lastly, this is not a PowerShell code/programming issue and not something PowerShell can fix relative to how you are trying to do this.

Otherwise, because it's a system-wide change.

$pass = ConvertTo-SecureString -AsPlainText $Password -Force So I tried to add credentials in order to automate the installation and changed the script to : $Username = 'domain\domain_adm' Yet when I run it, a message appears asking for elevated privileges. I created a PowerShell script using the following command: Get-WindowsCapability -Name RSAT* -Online | Add-WindowsCapability –Online My main goal is to use Get-ADuser command as a necessity to gain information from my Windows domain. I am facing a difficulty on installing RSAT to remote windows 10 workstations via gpo.
