AD how to disassemble the cn attribute?


Warning: count(): Parameter must be an array or an object that implements Countable in /home/styllloz/public_html/qa-theme/donut-theme/qa-donut-layer.php on line 274
0 like 0 dislike
14 views
As from the attribute cn=Ivanov Ivan Ivanovich to take the "I." i.e., to take only a middle name
by | 14 views

1 Answer

0 like 0 dislike
The posh, it's just a question of how you standardized the attribute. And - this is a regular string, parsite her space, and after the second take. Read operations on rows in power shell. As an example:

$cn = (Get-ADUser -Properties cn).cn
$cn.Split(" ")[3]
by

Related questions

0 like 0 dislike
2 answers
0 like 0 dislike
1 answer
0 like 0 dislike
1 answer
110,608 questions
257,187 answers
0 comments
40,253 users