I’m trying to understand why I get different results for this.
$computer = Get-ADComputer -identity ComputerName
$computer.Name gives me the computer name only.
“$computer.Name” gives me the full Distinguished Name instead.
Why is that?
Was trying to use it in the following expression which doesn’t work.
But would like to understand why the different behaviour between quoted and unquoted.