Running Scripts on Remote Computers

Use this forum to ask questions after your subscription maintenance expires or before you buy. Need information on licensing or pricing? Questions about a trial version? This is the right place for you. No scripting questions, please.
Forum rules
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
This topic is 4 years and 10 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
plautodfl
Posts: 30
Last visit: Thu Jun 09, 2022 6:09 am

Running Scripts on Remote Computers

Post by plautodfl »

To help you better we need some information from you.

*** Please fill in the fields below if you are currently using a Trial Version of the Product. If you leave fields empty or specify 'latest' rather than the actual version your answer will be delayed as we will be forced to ask you for this information. ***

Product: PowerShell Studio 2019 (64 Bit)
Build: v5.6.162
OS: Windows 10 Enterprise (64 Bit)
Build: v10.0.17763.0
32 or 64 bit OS:

OK- really having a blast with this product, just waiting on the corporate purchase wheels to churn.

One of the things I really liked was being able to run the script on the remote computer under the Remote Option.

I have a script that loops through a bunch of machines.
As part of my loop process how do I get the process to execute on the remote machine?



*** Please add details and screenshots as needed below. ***

DO NOT POST SUBSCRIPTIONS, KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM
Attachments
ServiceCenterCleanupHPMXLv1.ps1
(5.22 KiB) Downloaded 156 times
User avatar
brittneyr
Site Admin
Posts: 1655
Last visit: Thu Mar 28, 2024 1:00 pm
Answers: 39
Been upvoted: 30 times

Re: Running Scripts on Remote Computers

Post by brittneyr »

Are the machines you are looping through, you want to run this script on each machine?
If you are wanting to run this process remotely on each looped machine, you can try using the following cmdlet:

Code: Select all

Invoke-Command
You can provide the process you would like to run in the script block parameter and it allows you to specify the computer you would like to remote to.
Brittney
SAPIEN Technologies, Inc.
This topic is 4 years and 10 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.