I want some Moore

Blog about stuff and things and stuff...
mostly about SQL server and .Net
posts - 161, comments - 1488, trackbacks - 33

My Links

SQLTeam.com Links

News

Hi! My name is 
Mladen Prajdić  I'm from Slovenia and I'm currently working as a .Net (C#) and SQL Server developer. I'm also a MCP and MCTS for SQL Server. 
Welcome to my blog.

Search this Blog
 

My Blog Feed via Email


Get your Google PageRank
Users Online: who's online

Article Categories

Archives

Post Categories

Cool software

Other Blogs

Other stuff

SQL stuff

Exchange: Accept and Cancel Meeting Request with WebDav

In a lengthy article about WebDAV  i've written a long while ago I've explained how and what WebDAV is and what are the problems you might encounter.

Suggesting by the comments (over 200) it's a pretty popular topic but there's no help on the net for anything more complex than simple operations because

MSDN suggest that WebDAV is totally unsupported. So anything you do with it you're on your own.

Having said that let's see how to do those 2 things from the title:

 

Cancel a Meeting Request

 1. get the Meeting Request URI from the inbox

 2. get the associated appointment for that Meeting Request

          explained how in previous article under     

               Development problems and bugs - 3. Getting associated appointment from a meeting request reply

 3. modify (PROPPATCH) it with the setting the appointments stampdate to now

 4. modify (PROPPATCH) the appointment like this (change the dtstamp property to now):

<?xml version=\"1.0\" ?>
<a:propertyupdate 
        xmlns:a=\"DAV:\" 
        xmlns:n0=\"http://schemas.microsoft.com/exchange/\" 
        xmlns:n1=\"urn:schemas:calendar:\">
    <a:set>
        <a:prop>
            <n0:outlookmessageclass>IPM.Schedule.Meeting.Canceled</n0:outlookmessageclass>
            <a:contentclass>urn:content-classes:calendarmessage</a:contentclass>
            <n1:dtstamp>2007-08-22T15:36:52.696Z</n1:dtstamp>
            <n1:method>CANCEL</n1:method>
        </a:prop>
    </a:set>
</a:propertyupdate>

 5. move the appointment to ##DavMailSubmissionURI##

 

Accept a Meeting Request

 1. get the meeting request URI from the inbox

 2. get it's from and to properties (FROM property will be set to TO, and TO property will be set to FROM in the reply)

 3. copy the meeting request to the Calendar folder (now you have 2 identical meeting requests - one in inbox and one in calendar)

 4. move the meeting request from inbox to drafts folder

 5. modify (PROPPATCH) the meeting request in the Calendar folder like this (change the dtstamp property to now):

<?xml version=\"1.0\" ?>
<a:propertyupdate 
        xmlns:a=\"DAV:\" 
        xmlns:n0=\"http://schemas.microsoft.com/exchange/\" 
        xmlns:n1=\"urn:schemas:calendar:\" 
        xmlns:n2=\"http://schemas.microsoft.com/mapi/\" >
    <a:set>
        <a:prop>
            <n0:outlookmessageclass>IPM.Appointment</n0:outlookmessageclass>
            <a:contentclass>urn:content-classes:appointment</a:contentclass>
            <n1:dtstamp>2007-08-22T16:14:30.492Z</n1:dtstamp>
            <n1:meetingstatus>CONFIRMED</n1:meetingstatus>
            <n1:method>REQUEST</n1:method>
            <n2:responsestatus>3</n2:responsestatus>
        </a:prop>
    </a:set>
</a:propertyupdate>

  6. modify (PROPPATCH) the meeting request in the Drafts folder like this (change the dtstamp property to now):

<?xml version=\"1.0\" ?>
<a:propertyupdate 
        xmlns:a=\"DAV:\" 
        xmlns:n0=\"http://schemas.microsoft.com/exchange/\" 
        xmlns:n1=\"urn:schemas:calendar:\" 
        xmlns:n2=\"urn:schemas:httpmail:\" 
        xmlns:n3=\"urn:schemas:mailheader:\" 
        xmlns:n4=\"http://schemas.microsoft.com/mapi/\" >
    <a:set>
        <a:prop>
            <n0:outlookmessageclass>IPM.Schedule.Meeting.Resp.Pos</n0:outlookmessageclass>
            <a:contentclass>urn:content-classes:calendarmessage</a:contentclass>
            <n1:dtstamp>2007-08-22T16:18:07.532Z</n1:dtstamp>
            <n1:meetingstatus>CONFIRMED</n1:meetingstatus>
            <n1:method>REPLY</n1:method>
            <n2:subject>Accepted: yourOriginalSubjectHere</n2:subject>
            <n3:to>to_Email@this_is_the_from_property_value_of_the_received_meeting_request</n3:to>
            <n4:responsestatus>3</n4:responsestatus>
        </a:prop>
    </a:set>
</a:propertyupdate>

  7. move the item from Drafts to ##DavMailSubmissionURI##

 

 That should be it. Enjoy!

 

kick it on DotNetKicks.com
 

Print | posted on Wednesday, August 22, 2007 6:27 PM

Feedback

# re: Exchange: Accept and Cancel Meeting Request with WebDav

I am trying to use .NET, c# and webdav to create appointments and send meeting requests from my ASP 2.0 web application when people pick a class to attend. I have tried many different things and have been partially successful. I would love to send you my code I have for you to look over, or if you could send me a sample on how to do that I would appreciate it alot! Thanks in advance for your help!
1/9/2008 5:28 PM | Mike Fagan

# re: Exchange: Accept and Cancel Meeting Request with WebDav

what are you having problems with exactly?
1/9/2008 5:30 PM | Mladen

# re: Exchange: Accept and Cancel Meeting Request with WebDav

Tried to follow you accept meeting request guide, it failed at the 3 step and caused the Calendar to disapear from OWA!,
The only thing that resolved it was deleting the user and creating it empty.
(it wasn't a disaster since I did it on a test user).
can you please send a complete http sniff of the accept operation, it would be helpful if you can do the same for the cancel.

Thanks,
Eli
9/12/2008 7:08 PM | Eli

Post Comment

Title  
Name  
Email
Url
Comment   
Please add 3 and 1 and type the answer here:

Powered by: