How to know if my DirectoryEntry is really connected to my LDAP directory?

前端 未结 4 604
猫巷女王i
猫巷女王i 2020-12-20 16:48

I\'m connecting to a LDAP directory in C#, so I\'ve used the DirectoryEntry class.

When you do the \"new DirectoryEntry\" with address, login, and password it is sup

4条回答
  •  时光说笑
    2020-12-20 17:35

    Ok so marc_s's solution was approximately what i was doing (except i was looking for SchemaEntry and not NativeObject). But the timeout delay is much too long (the query is run to fill autocompletion values for a form). I think I actually prefer to pretend the connection is open and let the query run. That way, i can set my own, smaller, timeout delay.

提交回复
热议问题