Screenconnect commandline: Difference between revisions
Jump to navigation
Jump to search
(SCX CLI) |
No edit summary |
||
Line 23: | Line 23: | ||
[[Category | [[Category:ScreenConnect]] |
Revision as of 18:36, 13 March 2020
Enable Remote Execution
Set-ExecutionPolicy RemoteSigned
Show Processes Names Like sam* and Filter for name only
Get-Process sam* | Select-object name
Test if Service is Running
(Get-Service -Name 'Spooler').Status -eq 'Running'
Show Drives and Space Usage
get-psdrive -psprovider filesystem
Create a Desktop shortcut to a folder
$TargetFile = "C:\scan\"
$ShortcutFile = "$env:Public\Desktop\folder.lnk"
$WScriptShell = New-Object -ComObject WScript.Shell
$Shortcut = $WScriptShell.CreateShortcut($ShortcutFile)
$Shortcut.TargetPath = $TargetFile
$Shortcut.Save()