→ The Lansweeper Customer Excellence Awards 2024 - Submit Your Project Now! Learn More & Enter Here
‎08-09-2019 01:07 PM - last edited on ‎04-01-2024 04:36 PM by Mercedes_O
Hi Folks,
I am trying to launch the below command from the basic actions menu for an asset but the PowerShell window displays and then closes with no output
I have the command working from a normal PowerShell window on the Lansweeper server.
The two commands I have tried are below:
powershell.exe Enter-PSSession -ComputerName {computer}
powershell.exe set-executionpolicy bypass Enter-PSSession -ComputerName {computer}
Any ideas what I am doing wrong?
Solved! Go to Solution.
‎09-05-2019 11:36 PM
‎09-05-2019 11:36 PM
‎09-09-2019 01:10 PM
steveb wrote:
I got it to work. Try adding the -noexit parameter.
powershell.exe -noexit Enter-PSSession -ComputerName {smartname}
For anyone else, here is the how to I followed for enabling remote powershell sessions if you don't already have it setup.
remote powershell enable
‎09-05-2019 11:21 PM
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now