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

  • Home
  • SEARCH
  • 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 7038555
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T01:41:00+00:00 2026-05-28T01:41:00+00:00

I am building an Outlook 2010 addin to integrate it with some business software

  • 0

I am building an Outlook 2010 addin to integrate it with some business software and have trapped the ItemSend Event. I check if it is a MailItem and if it is I call the SaveAs function to save it as a .msg to the file system (in the users temp folder).

void Application_ItemSend(object Item, ref bool Cancel)
{
    if(Item is Outlook.MailItem)
    {
        Outlook.MailItem mailitem = (Outlook.MailItem)Item;
        string filename = "somefilename.msg";
        string path = System.IO.Path.GetTempPath();
        string fullPathName = path+filename;
        mailitem.SaveAs(fullPathName, Outlook.OlSaveAsType.olMSG);
    }
}

I go on to read the file contents and send the file to the server using webservices. It all works fine.

The issue I have is if I go and open the file that it saves, then Outlook opens it as a message still being composed and the user could very easily click the Send button again.

Is there a way to flag that the item has been sent before it gets saved so when opened after the fact it opens as a readable email rather than an in-composition email?

  • 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-28T01:41:01+00:00Added an answer on May 28, 2026 at 1:41 am

    Take a look at this post (and additionally at the last answer on that page), this might help you.

    (Makes use of ItemAdd event)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an Outlook 2010 addin, and I'm trying to create a custom context
I've been experimenting with building an Outlook 2010 addin in C#, using Visual Studio
Building my first SL MVVM application (Silverlight4 RC) and have some issues i don't
I'm getting this error when building a setup project for an outlook 2007 addin
I'm building an Outlook add-in in Visual Studio 2010, using VSTO with VB.net, to
I'm building an outlook addin, and I was wondering if there was any standard
I am building a shared-addin for Outlook. Inside the code, I am creating a
I am building a Outlook 2007 Addin using with VS2008 using IRibbonExtensibility. My simple
Building on this question: Django Celery Time Limit Exceeded? I have some tasks that
Building a Shopping Cart app. Some products have options, some don't. I visitor can

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.