M
mike
I'm needing a bit of help to fine tune my Filter property for a
DirectorySearcher. My context here is for a company phone directory. A
user enters the string they want to search for (in txtSearch) and hits
the Fire button.
The problem is that this picks up disabled accounts which I'd rather
didn't happen. I basically grabbed this string straight from somewhere
but don't really know what "anr " means.
ds.Filter = "(&(anr=" & txtSearch.Text & ")(objectCategory=person))"
I tried to change it to the following
ds.Filter = "(&(anr=" & txtSearch.Text & ")(objectCategory=person)
(AccountDisabled=false))"
but my search now returns zero results, no matter what. I got this
property name from the ADSI SDK on microsoft.com.
Can anyone help?
Thanks
Mike
DirectorySearcher. My context here is for a company phone directory. A
user enters the string they want to search for (in txtSearch) and hits
the Fire button.
The problem is that this picks up disabled accounts which I'd rather
didn't happen. I basically grabbed this string straight from somewhere
but don't really know what "anr " means.
ds.Filter = "(&(anr=" & txtSearch.Text & ")(objectCategory=person))"
I tried to change it to the following
ds.Filter = "(&(anr=" & txtSearch.Text & ")(objectCategory=person)
(AccountDisabled=false))"
but my search now returns zero results, no matter what. I got this
property name from the ADSI SDK on microsoft.com.
Can anyone help?
Thanks
Mike