looking for help with a quick powershell script

looking for help with a quick powershell script

avatar

I need a script that will output a list of the computer names for all of my sessions. If it matters the sessions are RDP sessions.

All Comments (4)

avatar

Hello,

What output would you like? Will CSV be ok?

Thanks

Maurice

avatar

yes CSV will be fine. Ideally include the folder name as well but I am sure I can figure that part out if complicates things.

avatar

Should be very straightforward:

get-rdmsession | select-object -property Name,HostResolved,Group

David F.

avatar

Hello,

Thank you David :)

Maybe just to add more things to your suggestion to get only the RDP sessions and send them into a CSV file.

get-rdmsession | where {$_.ConnectionType -eq "RDPConfigured"} | select-object -property Name,HostResolved,Group | Export-Csv c:\temp\test1.csv
Best regards,

Érica Poirier