Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6612237
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T20:04:24+00:00 2026-05-25T20:04:24+00:00

I am building an Email send application in delphi 7. Default email client on

  • 0

I am building an Email send application in delphi 7. Default email client on my machine is configured with lotus notes.
I have tried shellExecute command on ‘send’ button click in application. But in this ShellExecute pop up the lotus notes to user with subject, body etc and then user needs to click on Send button in lotus notes.

I want when user click on Send button of my application then automatically email should be sent using lotus notes. Can we do this using ShellExecute? I tried using Indy components also but I didn’t get the SMTP details. How can I find out SMTP server details?
thanks for help

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T20:04:24+00:00Added an answer on May 25, 2026 at 8:04 pm

    For sending e-mails using Lotus Notes (even if it looks for me like an overkill a bit) I found this post and tried to translate it to Delphi code but I can’t test it anywhere, so I can’t tell you if this works or not. I have left the original comments in there.

    uses
      ComObj, StrUtils;
    
    // Public Sub SendNotesMail(Subject as string, attachment as string,
    // recipient as string, bodytext as string,saveit as Boolean)
    // This public sub will send a mail and attachment if neccessary to the
    // recipient including the body text.
    // Requires that notes client is installed on the system.
    
    procedure SendNotesMail(const Subject: string; const Attachment: string;
      const Recipient: string; const BodyText: string; const SaveIt: Boolean);
    var
      Maildb: OleVariant;     // The mail database
      UserName: string;       // The current users notes name
      MailDbName: string;     // The current users notes mail database name
      MailDoc: OleVariant;    // The mail document itself
      AttachME: OleVariant;   // The attachment richtextfile object
      Session: OleVariant;    // The notes session
      EmbedObj: OleVariant;   // The embedded object (Attachment)
    begin
      Session := CreateOleObject('Notes.NotesSession');
    
      // Next line only works with 5.x and above. Replace password with your password
      Session.Initialize('password');
    
      // Get the sessions username and then calculate the mail file name
      // You may or may not need this as for MailDBname with some systems you
      // can pass an empty string or using above password you can use other mailboxes.
      UserName := Session.UserName;
      MailDbName := LeftStr(UserName, 1) + RightStr(UserName, (Length(UserName) - Pos(UserName, ' '))) + '.nsf';
    
      // Open the mail database in notes
      Maildb := Session.GETDATABASE('', MailDbName);
      if not Maildb.ISOPEN then
        Maildb.OPENMAIL;
    
      // Set up the new mail document
      MailDoc := Maildb.CREATEDOCUMENT;
      MailDoc.Form := 'Memo';
      MailDoc.sendto := Recipient;
      MailDoc.Subject := Subject;
      MailDoc.Body := BodyText;
      MailDoc.SAVEMESSAGEONSEND := SaveIt;
    
      // Set up the embedded object and attachment and attach it
      if Attachment <> '' Then
      begin
        AttachME := MailDoc.CREATERICHTEXTITEM('Attachment');
        EmbedObj := AttachME.EMBEDOBJECT(1454, '', Attachment, 'Attachment');
        MailDoc.CREATERICHTEXTITEM('Attachment');
      end;
    
      // Send the document
      MailDoc.PostedDate := Now; // Gets the mail to appear in the sent items folder
      MailDoc.SEND(0, Recipient);
    end;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am building an application which will send status requests to users (via email
I'm building an application that gives users the option to send out an email
I am trying to send an email from a site I am building, but
I'm building a application that sends a test message to another email, the program
I'm building a .NET application where I want to dynamically add an email address
Building a client-side swing application what should be notified on a bus (application-wide message
I need to send email notifications in my Java web application. I'm using Apache
I am building an application that will need to send emails on numerous occasions
I am building an iPhone application that generates an email with an attachment. The
I’m building email notification service, requirement is to send an email to user when

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.