+1 vote

How can i send response (Accept, Decline or Propose New Time) via Imap for iCalendar meeting request i have retreived from Exchange server?

retagged by

1 Answer

0 votes
Best answer

You should use SMTP for that. iCalendar responses are regular emails (same as the initial meeting request) with appointment object attached.

You should use Accept or Decline method on Appointment instance. Those methods return new Appointment object, that can be resend to the meeting organizer.

You should create a new message and add the appointment using MailBuilder.AddAppointment, finally send it using SMTP.

Appointment appointment = ...;

Appointment accepted = appointment.Accept("bob@example.org");

MailBuilder builder = new MailBuilder();
builder.Subject = "Meeting response";
builder.Text= "Bob has accepted the meeting.";
builder.From.Add(new MailBox("bob@example.org", "Bob"));
builder.To.Add(new MailBox("alice@example.org", "Alice"));


IMail email = builder.Create();

using (Smtp client = new Smtp())
    client.UseBestLogin("bob@example.org", "password");
by (272k points)
selected by