0
擁有csv的姓氏,名字,並且似乎無法將用戶解析爲其SamAccountName。無論我如何嘗試,我都會收到以下錯誤。以下是錯誤。從顯示名稱解析SamAccount名稱
我試圖不使用任務命令。
Get-ADUser : Cannot find an object with identity: 'doe, john' under: 'DC=corp,DC=company,DC=ORG'.
At line:1 char:11
+ get-aduser <<<< "doe, john"
+ CategoryInfo : ObjectNotFound: (doe, john:ADUser) [Get-ADUse
r], ADIdentityNotFoundException
+ FullyQualifiedErrorId : Cannot find an object with identity: 'doe, john' under: 'DC=corp,DC=company,DC=ORG'.,Microsoft.ActiveDirectory.Management.
Commands.GetADUser
不錯!謝謝JP。把這些命令放到一個變量中,然後用.samaccountname來得到結果。 – bruteForcePS 2013-05-08 06:47:39