dsSearch.SearchScope = SearchScope .Subtree; dsSearch.SizeLimit = 20000; dsSearch.PageSize = 1000; string [] propToLoadList = {"name","ou" }; dsSearch.PropertiesToLoad.AddRange(propToLoadList); SearchResultCollection searchCol = dsSearch.FindAll(); searchCol.Count始终为零吗?谁能帮忙解决这个问题? 同一个代码可以与AD Windows 2003完美配合,并且由于Exchange 5.5具有自己的目录服务,所以我必须查询我们的Exchange Server以获取用户或组. 有帮助吗?尽快? 穆斯塔法·阿拉法(Moustafa Arafa)解决方案 你好,穆斯塔法, > 感谢您的帖子!我建议将您的问题发布到其中之一 TechNet论坛»Exchange Server»一般讨论 位于此处: http://forums.microsoft.com/technet/showforum.aspx?forumid=831& siteid = 17& sb = 0& d = 1& at = 7& ft = 11&tf = 0& pageid = 0 . 祝您有美好的一天! Hi All, I'm trying to query distribution lists on Exchange 5.5 in C#.I have an experience to work to query Users,DLs in AD Windows 2003,but the same code when i ran it against Exchange 5.5 on Windows 2000 no enteries are returned.here is my code :string strRcptContainer = LDAP://MYSERVERIP;//Check to see if the dl is already presentDirectoryEntry deContainer = new DirectoryEntry(strRcptContainer);deContainer.Username = txtUsername.Text;deContainer.Password = txtPassword.Text;string strFilter = "(objectClass=group)";DirectorySearcher dsSearch = new DirectorySearcher(deContainer,strFilter );dsSearch.SearchScope = SearchScope.Subtree;dsSearch.SizeLimit = 20000;dsSearch.PageSize = 1000;string[] propToLoadList ={ "name", "ou" };dsSearch.PropertiesToLoad.AddRange(propToLoadList);SearchResultCollection searchCol = dsSearch.FindAll(); searchCol.Count is always Zero ? can any one help to how to fix that ? The Same Code is working Perfectly with AD Windows 2003,and since Exchange 5.5 has its own Directory Service,that's why i have to query our Exchange Server to get users or groups.Any Help ? ASAP ?Moustafa Arafa 解决方案 Hello Moustafa, Thank you for your post! I would suggest posting your question in one of the TechNet Forums » Exchange Server » General Discussions located here: http://forums.microsoft.com/technet/showforum.aspx?forumid=831&siteid=17&sb=0&d=1&at=7&ft=11&tf=0&pageid=0.Have a great day! 这篇关于Exchange 5.5中查询用户或组时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云! 07-12 00:32