This Test-QADObject (Test-QADPath) function I have created gives a quick true or false answer on whether a specific user, computer, group, OU already exists in your domain.
Test-QADObject dsotniko Test-QADObject 'OU=demo,DC=quest,DC=local' Test-QADPath k*
I have posted the whole code with proper help and parameter handling to poshcode. Here’s a simplified one for the blog:
function Test-QADObject { param($Identity) (Get-QADObject $Identity -DontUseDefaultIncludedProperties ` -WarningAction SilentlyContinue -ErrorAction SilentlyContinue ` -SizeLimit 1) -ne $null }
Subscribe by email
