Click here to Skip to main content
15,885,216 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

need some help with this question...we need to open up the Lotus Notes client from a JSP page..

Currently in the JSP we are opening up the Microsoft Outlook Client using ActiveXObject(Outlook.Application)

Could someone please help us with this as soon as possible.

The from email , to email , email subject and email body should get populated from the Request Scope.I got one solution but in that it is possible only to send the mails directly i need to open the lotus notes page.there are some methods like sendto,form,create .is there any method which opens the compose mail option when we click the submit button after entering all the details.Not only java script if the solution is in java also no problem

Basically the user would just click some link on a page and then Lotus Notes client should open up with the pre populated information. Finally the user would review the email contents , add any message they need to add in the email message body and then finally send the email.If possible send me the code also.plese help me soon.here i am giving the code that i previously used.this code helps us only to send the e mail directly with out opening the lotus notes..please check this and give me the correct solution

TIHS IS THE CODE WHICH I USED


HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>Lotus</title>
    <script language="javascript" type="text/javascript">
    function SendScriptMail()
{
var mToMail=document.getElementById('txtMailId').value
var mSub=document.getElementById('txtSubject').value
var mMsg=document.getElementById('txtContent').value
        var Maildb;
        var UserName; 
        var MailDbName;
        var MailDoc;
        var AttachME;
        var Session;
        var EmbedObj;
        var server;
        try
        {
// Create the Activex object for NotesSession
                Session = new ActiveXObject('Notes.NotesSession');
               if(Session !=null)
                 {
// Get the user name to retrieve database
                 UserName = Session.UserName;
     
// Retrieve database from username
           
 MailDbName ="164672.nsf" 
              

// Get database
                
           Maildb = Session.GetDatabase("", MailDbName);
//  open the database
                
            if(Maildb.IsOpen != true) 
           { 
                Maildb.OPENMAIL();
           } 
// Create the mail document
                                    
            MailDoc = Maildb.CREATEDOCUMENT();
// From email id (Username)
            MailDoc.Form = 'Memo';
// To email id 
            MailDoc.open=mTo Lotusnotes
            MailDoc.sendto = mToMail;
// Subject of the mail
            MailDoc.Subject = mSub;
// Content of the mail
            MailDoc.Body = mMsg
// if you want to save message on send give here true
            MailDoc.SAVEMESSAGEONSEND = false;
// send the mail (check ensure the internet connection)
            MailDoc.Send(true);
// save the mail in draft (no need of internet connection)
            MailDoc.Save(false, true);
// destroy the objects
            Maildb = null;
            MailDoc = null;
            AttachME = null;
            EmbedObj = null;
            Session.Close();
            Session = null;
            
            alert('Mail sent successfully');
            
            
            }
            else
            {
            alert('Mail not sent');
            }
            }
           catch(err)
           {
           if(err == '[object Error]')
           {
           alert('Error while sending mail,Please check Lotus Notes installed in your system');
           
           }
           else
           {
           alert('Error while sending mail');
           }
           } 
            
           
}
    </script>
</head>
<body>
    <table width="100%" height="100%">
        <tr>
            <td width="40%" height="130px">
            </td>
            <td>
            </td>
            <td width="40%">
            </td>
        </tr>
        <tr>
            <td>
            </td>
            <td>
                <table width="100%">
                    <tr>
                        <td style="color: Black; font-size: 10px; font-family: Verdana; text-align: left;"
                            width="50px" valign="top">
                            Mail Id</td>
                        <td>
                            <input id="txtMailId" style="color: #000000; font-size: 10px; font-family: Verdana;
                                height: 11px; text-align: left; top: auto; border: 1px solid #336699; text-decoration: none;
                                width: 176px;" type="text" maxlength="50" /></td>
                    </tr>
                    <tr>
                        <td style="color: Black; font-size: 10px; font-family: Verdana; text-align: left;"
                            valign="top">
                            Subject</td>
                        <td>
                            <input id="txtSubject" style="color: #000000; font-size: 10px; font-family: Verdana;
                                height: 11px; text-align: left; top: auto; border: 1px solid #336699; text-decoration: none;
                                width: 176px;" type="text" maxlength="50" /></td>
                    </tr>
                    <tr>
                        <td style="color: Black; font-size: 10px; font-family: Verdana; text-align: left;
                            height: 79px;" valign="top">
                            Content</td>
                        <td>
                            <textarea id="txtContent" cols="20" style="color: #000000; font-size: 10px; font-family: Verdana;
                                height: 75px; text-align: left; top: auto; border: 1px solid #336699; text-decoration: none;
                                width: 176px;"></textarea></td>
                    </tr>
                    <tr>
                        <td>
                        </td>
                        <td>
                            <input id="btnSend" type="button"  önclick="SendScriptMail();" style="font-family: Verdana; font-size: 11px; text-align: center;
                                top: auto; width: 60px; background-color: #A55129; border: 1px solid #336699;
                                text-decoration: none; font-weight: normal; color: #FFFFFF;" value="Send" />
                            <input id="btnCancel" style="font-family: Verdana; font-size: 11px; text-align: center;
                                top: auto; width: 60px; background-color: #A55129; border: 1px solid #336699;
                                text-decoration: none; font-weight: normal; color: #FFFFFF;" type="button" value="Cancel" /></td>
                    </tr>
                </table>
            </td>
            <td>
            </td>
        </tr>
        <tr>
            <td height="130px">
            </td>
            <td>
            </td>
            <td>
            </td>
        </tr>
    </table>
</body>
</html>


please try to reply as soon as possible..it's very urgent.

thanks in advance
madhuri
Posted
Updated 3-Jan-12 21:51pm
v12
Comments
Sergey Alexandrovich Kryukov 26-Dec-11 2:39am    
Lotus Notes? Oh, I really sorry for you.
--SA
Nagy Vilmos 3-Jan-12 7:14am    
Another puppy gone. Blotus Goats is the demon spawn, you have all our deepest sympathy.
Have you checked on their web site for idea? I'm not deranged enough to go there myself but it /might/ have some information.
Good luck!
Dylan Morley 4-Jan-12 3:54am    
I was going to write a comment about how bad Lotus Notes is, but been beaten to it :)

Haven't used that for about 15 years!!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900