Script_A.ps1 on Server A: The Script "Script_B.ps1": Script_C needs elevated permissions to execute. I can edit Script_A and Script_B but NOT Sc ...
Script_A.ps1 on Server A: The Script "Script_B.ps1": Script_C needs elevated permissions to execute. I can edit Script_A and Script_B but NOT Sc ...
currently I am working on a script that should give me the number of files that have been modified in the last 30 days or between 30 and 180 days or t ...
So, I'm trying to remotely remove some manually added printer from a separate machine. Problem is, I don't want to remove all of the printers, only on ...
I want to download a file from server and execute it, with single line command. I found this sollution iwr site.com/file.exe -OutFile file.exe; file.e ...
I'm trying to update the ip ranges in the azure Here's my code: error encountered: I tried to replace this: $NewSnatIpRange to "10.0.0.0/8" "10 ...
I'm converting my current backup solution for our whole environment to Powershell GUI application. My script is working as intended but now I'm trying ...
I am trying to execute a script remotely to get the list of service with exclusion of certain service currently in stopped state. I am not able to pas ...
How can I start a service on an Azure VM remotely? It seems impossible to do without Powershell being "Run as Administrator". Is there a way to launch ...
I'm trying to use $using:x inside an Invoke-Command itself called by Start-Job, but I can't figure it out: This outputs: I know I can simply pas ...
I am using Invoke-Command { & "powershell.exe" } -NoNewScope and getting error as belove. Error Image ...
I'm using Invoke-Command, but this question can be relevant to any command using splat. I essentially want to pass two sets of variables that will be ...
First time asking a question here after using it for a long time. I'm currently making a powershell script to delete userdata when they left the comp ...
I am trying to run series of commands on remote Windows Servers. Some of these servers are up and some of them not. To some I have access and to some ...
I have a script that does SQL backup and restore. It works with SQL Server 2014 Standard and SQL Server 2019 Standard. I am using either SQL Server m ...
i want to use a predefined function on a remote server with ps invoke and i need to send an object as parameter. This code always writes objects first ...
I'm trying to pass the value of the variable $DNSClientServerAddr inside an Invoke-Command -VMName. My option is the 'using' scope modifier. I can't s ...
I'm trying to run a command on a VM using Invoke-Command. The command should stop a program that processes jobs after it finishes its current job. It ...
This is what I've got in my Invoke-ProcessTable powershell script (snippet) $TenantId is hard coded in the script. and this is the error I'm get ...
I'm trying to pass some variables sort-of similar to the below, but it isn't passing back the updated/change data i want. In the small example below c ...
I've come across a problem which I can't seem to figure out. I have this piece of code which does exactly what I want. It searches for Windows Updates ...