We help IT Professionals succeed at work.
Get Started

Print Document in Lotus Notes using C#

solarissf
solarissf asked
on
1,461 Views
Last Modified: 2013-12-18
Hi guys... I'm still new to this but basically I am going to the last email in my "sent" folder, and wanting to print it.

So far I was able to find the last email in folder, but can't print it, any help would be GREATLY appreciated.!!!!
thanks!!!

private void PrintLastEmail()
{
//Lotus Notes Object Creation
NotesSession _notesSession = new NotesSession();
NotesDatabase _notesDataBase = null;
NotesDocument _notesDocument = null;
string sServerName =comboBox1.Text;//"NJROS1NML45/SERVER/Prudential"; //ConfigurationManager.AppSettings["NJROS1NML45/SERVER/Prudential"];
string sMailFile = "/Mail/" + login + ".nsf"; //"/Mail/x152169.nsf"; 
string password = login; //ConfigurationManager.AppSettings["x152169"];
object oItemValue = null;
_notesSession.Initialize(password);
_notesDataBase = _notesSession.GetDatabase(sServerName, sMailFile,
false);
//If the database is not already open then open it. 
if (!_notesDataBase.IsOpen)
{
_notesDataBase.Open();
}

Open in new window

Comment
Watch Question
Groupware Consultant
CERTIFIED EXPERT
Commented:
This problem has been solved!
Unlock 2 Answers and 21 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE