Important Notice: On February 29th, this community was put into read-only mode. All existing posts will remain but customers are unable to add new posts or comment on existing. Please feel to join our Community Discord for any questions and discussions.

Results for a Powershell command

I need to know if a certain file is in a certain location on hundreds of desktops. I'm able to successfully send the Powershell command and I do get a response but I have to open the output log to see the results. This has to be done for every host I sent the command to and is very time consuming. Is there a way to get the results without checking each output log?

1

Comments

3 comments
Date Votes
  • 2
  • I appreciate the quick response but that solution would still require me to open each device to find the status of the folder.

    1
  • You can create Collections to see which computers do and do not have the file.

    If you want to stay in Deploy, you can make your PowerShell script throw a non-zero exit code if the file is missing.

    if ( -Not ( Test-Path "C:\Path\To\TheFile.txt" ) ) {
    Exit 10
    }
    1