Here I will explain it in detail, how we can construct the ICS file and send as an attachment in the email.
First create a method
public void SendmailWithIcsAttachment()
{
//Now we have
to set the value to Mail message properties. As shown below.
//Note Please change it to correct mail-id to use
this in your application
msg.CC.Add(new MailAddress("[email protected]", "DEF"));// it is optional,
only if required msg.Subject
= "Send mail with ICS file as an Attachment";
msg.Body = "Please Attend the meeting with this schedule";
msg.Subject = "Send
mail with ICS file as an Attachment";
msg.Body
= "Please Attend the meeting with this
schedule";
Now will see the Sending mail part
}
Happy Coding!!!