Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Lotus Notes Session.Initilize() Stops working (hangs)

Posted on 2007-07-23
9
Medium Priority
?
1,715 Views
Last Modified: 2013-11-26
Hi,

I am using a Web Frontend developed in ASP.NET with VB to connect to a Lotus Notes Database Like this:

Dim s As New Domino.NotesSession
Call s.Initialize("12345") 'The password of the Notes Id on the server is 12345

This is working - sort of :)

It connects fine, for a while, then it just stops working
It hangs on the s.Initialize Function. I don't receive any error messages, no timeouts..
the only way to get it working again is to restart the server. (which is busy and then has to restart at night)

Why would it work and just stop working.??
Thanks in Advance,

0
Comment
Question by:PierreBeukes
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 63

Expert Comment

by:SysExpert
ID: 19547664
1) Are you closing your sessions properly ?

2) DId you check to see if this has multiple instances that may be causing issues ?

3) Did you check the Notes Server log.nsf ?

4) Have you added any debugging code ?

I hope this helps !
0
 
LVL 3

Author Comment

by:PierreBeukes
ID: 19547991
1) In VB.net - s (the notes session variable) doesn't seem to have a close propery to call, it is connecting in its own function, so it should dispose of the variable once it exits the function.... maybe it doesn't close the session properlly.

2) No I have not.. how can i check that? because evertime the function gets called, it will create its own instance of the variable.

3) ... No, I will check the log.nsf file - this should be on the server in the data directory right?

4).  No, it is from VB and when it executes the line to initialize - it is on that line that it hangs on - i don't receive any error messages though.

Thanks for the response, looking forward to your answers.
Ciao
0
 
LVL 46

Accepted Solution

by:
Sjef Bosman earned 1000 total points
ID: 19548272
Hello PierreBeukes,

Some info from the Notes Help databases:

"To access the Domino Objects, create a NotesSession object with either the following:
Dim session As New NotesSession
Or:
Dim session As NotesSession
Set session = CreateObject("Lotus.NotesSession")
"
So, instead of the Domino.NotesSession, I'd use plain NotesSession or Lotus.NotesSession.

"You must explicitly initialize a COM session with one of the following NotesSession methods. These methods do not apply to LotusScript applications.
Call session.Initialize("passwordOptional")
Call session.InitializeUsingNotesUserName("name", "passwordOptional")
The parameters are all strings. The name parameter can be an empty string. The password parameter is optional.
Initialization occurs as follows:
Initialize: this method can be used on a computer with a Notes client or Domino server and bases the session on the current user ID. If a password is specified, it must match the user ID password. If a password is not specified, the user is prompted for a password as required and as the software permits. If the software does not support prompting (for example, VBScript under ASP/IIS), you must supply the password or the user ID must not have one.
"
I suppose you have Notes installed locally?

Regards,
   Sjef
0
Veeam and MySQL: How to Perform Backup & Recovery

MySQL and the MariaDB variant are among the most used databases in Linux environments, and many critical applications support their data on them. Watch this recorded webinar to find out how Veeam Backup & Replication allows you to get consistent backups of MySQL databases.

 
LVL 63

Expert Comment

by:SysExpert
ID: 19549105
2) Use the Process explorer from http://www.sysinternals.com/ ( now Microsoft owned )  to check for  multiple instances.

3) Yes in the data dir

4) Add debug code  ON error or similar and capture an error info.

I hope this helps !
0
 
LVL 31

Assisted Solution

by:qwaletee
qwaletee earned 1000 total points
ID: 19550179
1) We alsoways make it a parctice to NOT put passwords on our server files, because of restart issues

2) You can also try connecting without the Notes ID and password -- there is a version called NotesSession.InitializeUsingNotesUser Name.  This allows you to pass the ID name and the **web** password, instead of relying on the server.ID file and the server's password.
0
 
LVL 3

Author Comment

by:PierreBeukes
ID: 19590682
qwaletee: , What do you mean by This allows you to pass the ID name and the **web** password, instead of relying on the server.ID file and the server's password.

any examples on this?
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 19594376
Sure.  Let's say you want to have the rights of a user names "Automatic Web Processes/PB Companies" and you have registered that user with a password of "on-the-Web-PW" (HTTP password value)

You can then run an ASP.NET script on your Domino server with the following code:

Dim session As NotesSession
session = CreateObject("Lotus.NotesSession")
session.InitializeUsingNotesUserName ("Automatic Web Processes/PB Companies", "on-the-Web-PW")


Everything else works the same. You are limited to accessing NSF files locally. If you have a way to call out to Java routines, you could also do the same remotely using NCSO.jar or NCSO.cab
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

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

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.
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
As many of you are aware about Scanpst.exe utility which is owned by Microsoft itself to repair inaccessible or damaged PST files, but the question is do you really think Scanpst.exe is capable to repair all sorts of PST related corruption issues?
Suggested Courses
Course of the Month13 days, 13 hours left to enroll

580 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