NotesDirectory.LookupNames picks only the first name of names list

I try to do a NotesDirectory.LookupNames for two names contained in an array. But it searches only for the name in the array’s first element.

I took a look at the clients debug output (set by notes.ini-parameters client_clock=1

debug_outfile=c:\temp\imdebug.txt

). This shows, there is only one call to NAMESLookup32 with only the first name of the array.

But Designer Help states:

Set notesDirectoryNavigator = notesDirectory.LookupNames(view$, names, items[, partialmatches])

Parameters

view$

The name of the view in which to look up names.

names

Variant. The names to be searched in the view. Entries must match one of these names to be searched for items.

So I wonder, if I’m doing something wrong. Or is the help wrong?

Would be happy to hear of other or the same experiences.

Thanks in advance,

Boerries

Subject: show your code

what do you have in Items? How do you treat the returned value(s) from Set notesDirectoryNavigator? The more info you give, the more likely you’ll get some help.

Subject: Here it is

Yes, I forgot the code. Here it is:

Dim session As New NotesSession

Dim dirServer As NotesDirectory

Dim dirnavServer As NotesDirectoryNavigator

Dim arstrNames(1) As String

Dim lngMatches&

Set dirServer = session.GetDirectory(“Testserver/Testunternehmen”)

arstrNames(0) = “Schmitz”

arstrNames(1) = “Meier”

Set dirnavServer = dirServer.LookupNames(“($Users)”, arstrNames, “CompanyName”, True)

lngMatches = dirnavServer.CurrentMatches

Result: lngMatches = 1.

Both names are available in this view (“($Users)”). It doesn’t matter, whether the first name is “Schmitz” and second is “Meier” or if the first is “Meier” and the second is “Schmitz”.

Always the same result: only one match is returned.

Subject: Problem solved

That was my fault, sorry:

I misinterpreted the property CurrentMatches. It gives the number of matches for the CurrentMatch only, not for all found names.

Thank for your interest and response.