Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

4.6 Updating a Calendar Item

The following example demonstrates a client request to update the subject, the location, and the end time of a meeting, and the server response. In this example, an updated meeting request is sent to all attendees and a copy is saved in the organizer’s Sent Items folder.

Request:

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance
      xmlns:m=http://schemas.microsoft.com/exchange/services/2006/messages
      xmlns:t=http://schemas.microsoft.com/exchange/services/2006/types
      xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Header>
      <t:RequestServerVersion Version="Exchange2010" />
   </soap:Header>
   <soap:Body>
      <m:UpdateItem ConflictResolution="AlwaysOverwrite" SendMeetingInvitationsOrCancellations="SendToAllAndSaveCopy">
         <m:ItemChanges>
            <t:ItemChange>
               <t:ItemId Id="AAMkA=" ChangeKey="DwAAA" />
               <t:Updates>
                  <t:SetItemField>
                     <t:FieldURI FieldURI="item:Subject" />
                     <t:CalendarItem>
                        <t:Subject>Status Meeting - Rescheduled/Moved</t:Subject>
                     </t:CalendarItem>
                  </t:SetItemField>
                  <t:SetItemField>
                    <t:FieldURI FieldURI="calendar:Location" />
                    <t:CalendarItem>
                       <t:Location>Conf Room 34</t:Location>
                    </t:CalendarItem>
                  </t:SetItemField>
                  <t:SetItemField>
                    <t:FieldURI FieldURI="calendar:Start" />
                    <t:CalendarItem>
                      <t:Start>2009-03-05T17:00:00Z</t:Start>
                    </t:CalendarItem>
                  </t:SetItemField>
                  <t:SetItemField>
                    <t:FieldURI FieldURI="calendar:End" />
                    <t:CalendarItem>
                      <t:End>2009-03-05T18:00:00Z</t:End>
                    </t:CalendarItem>
                  </t:SetItemField>
               </t:Updates>
            </t:ItemChange>
         </m:ItemChanges>
      </m:UpdateItem>
   </soap:Body>
</soap:Envelope>

Response:

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap=http://schemas.xmlsoap.org/soap/envelope/
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns:xsd="http://www.w3.org/2001/XMLSchema">
   <soap:Header>
      <t:ServerVersionInfo MajorVersion="8" MinorVersion="1" MajorBuildNumber="344" MinorBuildNumber="0" Version="Exchange2010" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" />
   </soap:Header>
   <soap:Body>
      <m:UpdateItemResponse xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages">
         <m:ResponseMessages>
            <m:UpdateItemResponseMessage ResponseClass="Success">
               <m:ResponseCode>NoError</m:ResponseCode>
               <m:Items>
                  <t:CalendarItem>
                     <t:ItemId Id="AAMkA=" ChangeKey="DwAAA" />
                  </t:CalendarItem>
               </m:Items>
               <m:ConflictResults>
                  <t:Count>0</t:Count>
               </m:ConflictResults>
            </m:UpdateItemResponseMessage>
         </m:ResponseMessages>
      </m:UpdateItemResponse>
   </soap:Body>
</soap:Envelope>
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.