locked
Sending meeting email to outlook using asp.net RRS feed

  • Question

  • User-1713550851 posted

    Hi

    I am trying to send meeting email to outlook user from asp.net

    my code is as follows:

    Dim oAppointment As Microsoft.Office.Interop.Outlook.AppointmentItem = oApplication.CreateItem(Microsoft.Office.Interop.Outlook.OlItemType.olAppointmentItem)

    oAppointment.Subject = "Testing Appointments with OOM in VB.NET"

    oAppointment.Body = "Test Appointment"

    oAppointment.Start = appointmentdate

    oAppointment.End = appointmentdate.AddHours(1)

    oAppointment.ReminderSet = True

    oAppointment.ReminderMinutesBeforeStart = 5

    ' oAppointment.BusyStatus = Microsoft.Office.Interop.Outlook.OlBusyStatus.olTentative

    oAppointment.MeetingStatus = OlMeetingStatus.olMeeting

    oAppointment.AllDayEvent = False

    oAppointment.RequiredAttendees = someemail@address.com

    oAppointment.Send()

    oAppointment = Nothing

    oApplication = Nothing

     

    I get the error message "Exception from HRESULT: 0x80004004 (E_ABORT)"

    Am I doing somthing wrong? what is the right way? Thanks in advance.

    Friday, February 15, 2008 9:46 AM

Answers

  • User-1713550851 posted

    I found the solution. There is nothing wrong with the code. But I didn't have email set up in my outlook, so at runtime this error was thrown.

    After I set up the email in outlook, it performed the desired action.

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, February 15, 2008 1:19 PM
  • User-1713550851 posted

    My development machine didn't have outlook in it. You must have Outlook in the server to send meeting request from outlook. Since my application is web based and the hosting server doesn't have Outlook in it , i have to use an alternate way to do that. (the code worked when i installed outlook in the development server). I used .ics calendar to send meeting request through system.net. It works like charm.If you want i can forward you  the class. (i am out of office today and tomorrow).

     

    Shakira 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, June 29, 2009 5:04 PM

All replies

  • User-1713550851 posted

    I found the solution. There is nothing wrong with the code. But I didn't have email set up in my outlook, so at runtime this error was thrown.

    After I set up the email in outlook, it performed the desired action.

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, February 15, 2008 1:19 PM
  • User772656366 posted

    Moni,


    I have the same error. You said it worked after you set up email in outlook. How do you mean set up email. I am using a domain account to send these appointments. I can login as that user and open outlook and manually send emails and appointments. Is this enough or is there something else I am missing? Thanks.

    Tom

    Monday, June 29, 2009 3:50 PM
  • User-1713550851 posted

    My development machine didn't have outlook in it. You must have Outlook in the server to send meeting request from outlook. Since my application is web based and the hosting server doesn't have Outlook in it , i have to use an alternate way to do that. (the code worked when i installed outlook in the development server). I used .ics calendar to send meeting request through system.net. It works like charm.If you want i can forward you  the class. (i am out of office today and tomorrow).

     

    Shakira 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, June 29, 2009 5:04 PM
  • User772656366 posted

    Thank you very much, Shakira! I'd appreciate it if you could send me the code to mylarges@yahoo.com.

    Wednesday, July 1, 2009 7:27 AM
  • User1741410576 posted

    hi can u tell me how you did and send the coding to aarch_sk@yahoo.co.in

    Wednesday, July 29, 2009 10:46 PM