How can I programmatically cancel an outlook meeting with asp.net VB?

后端 未结 2 886
难免孤独
难免孤独 2021-01-06 06:03

I can programmatically create a meeting request that is sent to the user through code and appears in Outlook mail where the user can accept the request and if accepted the a

2条回答
  •  情书的邮戳
    2021-01-06 06:40

    ANSWERED

    To cancel the meeting and have it removed from the outlook calendar you need to change the Method from "REQUEST" to "CANCEL" for the event that sends the cancellation request.

    msg.Body = strBody.ToString()
    
    Dim str As New StringBuilder()
    str.AppendLine("BEGIN:VCALENDAR")
    
    'PRODID: identifier for the product that created the Calendar object
    str.AppendLine("PRODID:-//CARS//Outlook MIMEDIR//EN")
    str.AppendLine("VERSION:2.0")
    '''ORIGINAL-CHANGE TO CANCEL'''
    'str.AppendLine("METHOD:REQUEST")
    '''NEW - CHANGE TO CANCEL'''
    str.AppendLine("METHOD:CANCEL")
    '''Everything else remains the same. Will work and remove meeting from calendar.'''
    

提交回复
热议问题