I am trying to get the contents of all users' Startup folders. I have created a small script that does this (below). The problem I ran into is that a few of the target servers are 2008 and do not have PS 3.0 or higher and does not seem to support applying a property by using the .PROPERTY method (Line 2, $allusers = $users.name)
I would appreciate any help and thank you in advance.
$users = get-childitem c:\users
$allusers = $users.name
foreach ($alluser in $users)
ls "c:\users\$alluser\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup"