Das Notes Forum

Domino 9 und frühere Versionen => ND6: Entwicklung => Thema gestartet von: Toma Bogdan am 14.07.04 - 13:43:20

Titel: how to get the server name and the number of the mailboxes with C/C++ API ?
Beitrag von: Toma Bogdan am 14.07.04 - 13:43:20
I have a server task and I need to get the number of the mailboxes from the server.

It is ok if the Address Book has just one server; the problems appears when I have 2 or more servers on same domain because the search on AddressBook returns Nothing

With C/C++ API the LNDatabase.GetServer() (which returns the server name on a DB resides) returns NULL if the DB resides on the current server). The LNNotesSession.GetUserName() gets the nameserver from the ID, but if there are more than 1 ID on a workstation it returns the value from the last ID accessed.

Is another solution to get the server name and the number of the mailboxes ?
Titel: Re:how to get the server name and the number of the mailboxes with C/C++ API ?
Beitrag von: eknori am 14.07.04 - 14:02:18
I use to use the following lines to retrieve the server name

//*================================================
//* Get ServerName
//* ================================================
STATUS         error;
char szServer[MAXUSERNAME+1];
error = SECKFMGetUserName (szServer);