Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2014
157
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.87 KB | None | 0 0
  1. srch.PropertiesToLoad.Add("homephone")
  2. srch.PropertiesToLoad.Add("mail")
  3. srch.PropertiesToLoad.Add("mobile")
  4. srch.PropertiesToLoad.Add("telephoneNumber")
  5.  
  6. Try
  7. results = srch.FindAll()
  8. Catch ex As Exception
  9. End Try
  10.  
  11. For Each result In results
  12. Dim myKey As String
  13. Dim myResultPropCollection As ResultPropertyCollection
  14.  
  15. myResultPropCollection = result.Properties
  16.  
  17. For Each myKey In myResultPropCollection.PropertyNames
  18. Dim tab1 As String = " "
  19. Dim myCollection As Object
  20. Select Case myKey
  21. Case "mobile" ' Telephone Number
  22. For Each myCollection In myResultPropCollection(myKey)
  23. phone = myCollection.toint
  24. Next myCollection
  25. End Select
  26. Next myKey
  27. Next
  28. Return phone
  29. End Function
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement