How does the COM API find the current Notes ID?

I am currently trying to setup some code I wrote which uses the COM API under .NET to access an R5 Notes DB using a 6.5.1 client on another persons machine. They have the client installed and are able to login to their account properly through the Notes client. The problem is, when I call Session.Initialize(password) Notes throws a “cannot find Notes ID” exception.

I’ve looked in the notes.ini file on this other machine (in the c:\lotus\notes directory) and it contains a reference to the correct .ID file. It seems that this other persons Notes environment is the same as mine yet the code does not work on their machine, so there must be some configuration difference.

What exactly is used to find the path to the Notes ID and does anyone have any suggestions on how to address this issue? Thanks,

-mark

Subject: How does the COM API find the current Notes ID?

Leave the password out of the deal and call Session.Initialize(). The password should not be in your code anyway both because it poses a severe security risk and because the user may be forced to change his/her password. The user should log in with their own credentials – the ID file can be set with File->Security->User Security to not ask for a password if the id is already open and in use (Do not prompt for password from other Notes-based programs).

The notes.ini drives the whole deal – it holds the current location, KeyFileName, MailServer – the whole nine yards. “A valid names.nsf” is a requirement, since it holds all of the connection information for the location, which ID files can use the current location, etc. The .ini contains the information as it was at last logout.

Subject: RE: How does the COM API find the current Notes ID?

This is a web based application running under IIS and the password is configurable in a web UI.

The issue is it works on my machine but the code doesn’t run on the second machine with said error. Since the notes.ini on both machines is the same (and valid) - at least in terms of the keyfilename etc. - the only thing I can think of is that for some reason Notes can’t access the notes.ini file on the second machine. I’ve been experimenting with directory security on the Notes folder (giving access rights to the ASPNET user), making sure c:\lotus\notes is in the system path, etc. but I’m really at a loss and nothing has worked.

Subject: How does the COM API find the current Notes ID?

This is what the help says:

“The Domino COM objects must be able to locate a valid names.nsf file, looking first in the Domino or Notes program directory and then at the PATH system variable. The KeyFileName setting in the names.nsf file specifies the user ID that COM uses.”

But I can’t find any reference to KeyFileName in names.nsf… I do see it in notes.ini but the other person trying to run this code has a notes.ini that is the same as mine and Notes still claims that it can’t find the Notes ID.

Subject: The KeyFilename= parameter is in the notes.ini file.