#7494
MA
Participant

quote:


Originally posted by lp_irovetz:
Hi,

Is there someone who know how to find ressource in Novell Address book ?

I used Two types of ressource (Cars and Rooms), the only way i’d found was to browse the AD and test ObjType property. But With more than 3000 entries, it’s slow. Frown

Thanks for help

L.P. Irovetz
ARCANE GroupWare


If you know the email-address of the resource then you can use the AddressBookEntries.Find(String Condition) method to find the resource from the address book entries collection. The filter exprtession support a different set of filtering operations, see the Object API documentation for more information. I don’t think you can provide object type in this filter expression.

Another thought, if you don’t know the email-address of the resource items then may be you have to iterate through all entries and remember the email-addresses of the resources. The sample code below use the Find() method to find a contact using the email-address…

dim oGWBook
dim oEntry
dim oFindResults

set oGWBook = groupwise.account.addressbooks.item(“Novell GroupWise Address Book”)

iFilterSyntax = “(<E-Mail Address> MATCHES “”testresource.DOMAIN@COMPANY.com””)”

set oFindResults = nothing
set oFindResults = oGWBook.addressbookentries.find(iFilterSyntax)

if oFindResults is nothing then
exit sub
end if

msgbox oFindResults.count

for each oEntry in oFindResults
msgbox oEntry.DisplayName
next

set oEntry = nothing
set oFindResults = nothing
set oGWBook = nothing

Hope this helps.
MA Cool