Count the number of objects in folders on remote servers

@Olaf

$nid = (Get-Process 'notepad', 'pdf24').id

if($nid -eq $null)
    {Write-Host 'No running processes'}
    else{
    Stop-Process -Id $nid -Verbose -force
    Wait-Process -Id $nid
    }

Probably the easiest option is to do it like this