I've got code that successfully sends a Meeting Request to Outlook users - when they receive the message, it appears as a calendar invite with Accept/Decline buttons at the top. Works great.
I recently added logic to include attachments in the message - however when Outlook users receive Meeting Requests with attachments, they no longer look like calendar invites in Outlook. Instead, they look like regular email messages - no Accept/Decline buttons at the top.
To paraphase the code:
MailMessage msg = new MailMessage();
msg.From = AppSettings.GetAppSetting("emailFrom");
msg.To = EmailAddresses;
Appointment cal = new Appointment(msgLocation, msgTitle, msgDescription, dtstart, dtend, msg.From[0], EmailAddresses);
if (properties.ListItem.Attachments.Count > 0)
{
// code for adding attachments
}
//add the appointmentto mail message
msg.AddAlternateView(cal.RequestApointment(0));
// send the message with the meeting request
client.Send(msg);
Looking for advice on how I might remedy this issue. Thanks in advance.