Hello,
I need to find RDM session by ID - no matter if it is Connection or SubConnection.
I'm using code like this:
$rdmSession = Get-RDMSession | Where-Object { $_.ID -eq $RDMGuid }
But, this does not include SubConnection.
Thank you for any idea.
Ivo
Hi Ivo,
Sub connections are stored in the SubConnections array inside your session.
They can be accessed like so
$rdmSession = Get-RDMSession | Where-Object { $_.ID -eq $RDMGuid }
$rdmSession.SubConnections
I don't think there is any way right now. We could add a -ID parameter to the Get-RDMSession command, but it would essentially do exactly what Where-Object is doing, only internally.
I hope this helps, let me know if it doesn't
Regards
Jonathan Lafontaine
Hi Jonathan,
thank you for quick answer.
I know about $rdmSession.SubConnections.
Of course I can handle it by some PS code, but using something like
$rdmSession = Get-RDMSession -ID '12132154-4654645-45545' -IncludeSubConnection $rdmAllSessions = Get-RDMSession -IncludeSubConnection
would be more elegant...
Thank you.
Best regards,
Ivo
That's is an idea we can explore.
Jonathan Lafontaine