developerWorks  >  Lotus  >  Forums & community  >  Notes/Domino 8 Forum

Notes/Domino 8 Forum



Feedback Type Problem
Subject Problems in c# with session.initialize
Product Area Notes 8 Client
Technical Area Application development
Platform Windows XP client
Release 8.0
Reproducible Always
I wrote a little program to send a mail via Lotus Notes.
First time i run the program it works fine.
Second time i start the program i get the message "Try to connect to Notes" but i never get the message "Session initialized"
The programm is in the taskmanager but it hungs.

Any idea what is wrong ?

OS: Windows XP
Lotus Notes: 8.5.3
Language: C# with VS2010


MessageBox.Show("Try to connect to Notes");
try {
Notes = Type.GetTypeFromProgID("lotus.Notessession");
session = Activator.CreateInstance(Notes, true);
Notes.InvokeMember("Initialize", BindingFlags.Public | BindingFlags.InvokeMethod | BindingFlags.Instance, null, session, null);
MessageBox.Show("Session initialized");

...etc....
}
catch(Exception e) {
MessageBox.Show(null, "Error: " + e.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
}

Feedback number WEBB8VNA8Y created by Christoph Bezzola on 05/25/2013

Go back