Solved

Initializing Notes Session with VBScript

Posted on 2003-12-09
5
9,437 Views
Last Modified: 2007-12-19
i am ASP developer and this is the first time i deal with Lotus Notes.

I am trying to initialize an Lotus Notes Session.  however, i got an error "An exception of type 'NotesSession:Notes error: could not open the ID file' was not handled"

when i try to use InitializeUsingNotesUserName() with username and password, i got a different error message "'An invalid username/password' was not handled".

here's that section of the code:

Dim s
set s = CreateObject("Lotus.NotesSession")
Call s.Initialize("password")

'and then process documents.....


some environment info.:
i am running win2k, with lotus notes client installed.  Lotus Domino Server is not installed.

i have checked the notes.ini file, KeyFilename=user.id.  i've tried changing it to the full path, but didn't help.

i noticed if i used InitializeUsingNotesUserName() without passing parameters, then i'm fine and have no problem initializing, however, come back an error saying anonymous user not allowed to open database.

what should i do????
0
Comment
Question by:asenna25
  • 3
  • 2
5 Comments
 
LVL 13

Expert Comment

by:CRAK
ID: 9915106
I know nothing about VBscript, but perhaps this helps to set you on the right track:

Set session = CreateObject("Lotus.NotesSession")
Call session.Initialize("passwordOptional")
Call session.InitializeUsingNotesUserName("name", "passwordOptional")
Set db = session.getDatabase("","")

I copied it (I won't reveil that) from http://www.experts-exchange.com/Applications/Email/Lotus_Notes/Q_20680718.html 
If you post a request under community support to move this question to the lotus notes topic area, then perhaps my friend qwaletee can help you any further if you get stuck. That way you don't have to spend another 500!
;-)
0
 

Author Comment

by:asenna25
ID: 9915694
thanks for replying my post!

that's what i did - passing the password with Initialize(), and i also tried passing username and password with InitializeUsingNotesUserName() - but neither on of them work...

currently, my user.id file is located in C:\Program Files\lotus\notes\data, and i hv this full path in the keyfilename.  is that right?

thanks for the suggestion, i'll post the question again under Lotus Notes.

thanks again.
0
 
LVL 13

Accepted Solution

by:
CRAK earned 500 total points
ID: 9918768
I'm not sure how VB picks up the correct location of the id file. In notes it's notes.ini that stores the location of the last id that was used. You can also define a file (+path) in the location document, but neither is defined here...

Community support can MOVE the question for you.
Otherwise, if you create a new one in the notes topic area, please ask them to close/delete this one and refund your points. Otherwise it will remain open for months untill a moderator comes along to close it.
0
 

Author Comment

by:asenna25
ID: 9928640
crak,

your friend qwaletee definitely gives me lotsa good pointers.  thanks a lot!
0
 
LVL 13

Expert Comment

by:CRAK
ID: 9931154
You're welcome! Thanks for the points! 500 * A, only to get you in a topic area where somebody else is still supposed to pick up the question?! That's very generous!
Well, you know where to turn to the next time when you need a hand!
;-))
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is an old article, please see an updated version of this article, located here: http://www.experts-exchange.com/articles/23619/Notes-8-5x-Windows-7-Notes-info-and-tips.html
Article by: Rob
Notes 8.5 Archiving Steps and Tips This article covers setting up a Notes archive, and helps understand some of the menu choices making setting up and maintaining a Notes archive file easier.
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question