Hi all!
Need support with one little question I can't solve myself.
In our company we use Exchange 2010 Server, but, at first I want to say that I'm not Exchange specialist.
I want to create task in Exchange via EWS and SOAP and this simple part I have successfully done with next XML code:
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
<soap:Header>
<t:ExchangeImpersonation>
<t:ConnectingSID>
<t:PrimarySmtpAddress>user@mail.com</t:PrimarySmtpAddress>
</t:ConnectingSID>
</t:ExchangeImpersonation>
</soap:Header>
<soap:Body>
<CreateItem xmlns="http://schemas.microsoft.com/exchange/services/2006/messages">
<Items>
<Task xmlns="http://schemas.microsoft.com/exchange/services/2006/types">
<Subject>Test task with reminder before and after</Subject>
<Body BodyType="Text">Please, check your task.</Body>
<ReminderDueBy>2013-07-04T14:45:00.000</ReminderDueBy>
<ReminderIsSet>true</ReminderIsSet>
<ReminderMinutesBeforeStart>15</ReminderMinutesBeforeStart>
<DueDate>2013-08-04T15:00:00</DueDate>
<StartDate>2013-07-04T15:00:00</StartDate>
<Status>NotStarted</Status>
</Task>
</Items>
</CreateItem>
</soap:Body>
</soap:Envelope>
But when I want to assign this task to other users, I try to use <DisplayTo> XML element:
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
<soap:Header>
<t:ExchangeImpersonation>
<t:ConnectingSID>
<t:PrimarySmtpAddress>user@mail.com</t:PrimarySmtpAddress>
</t:ConnectingSID>
</t:ExchangeImpersonation>
</soap:Header>
<soap:Body>
<CreateItem xmlns="http://schemas.microsoft.com/exchange/services/2006/messages">
<Items>
<Task xmlns="http://schemas.microsoft.com/exchange/services/2006/types">
<Subject>Test task with reminder before and after</Subject>
<Body BodyType="Text">Please, check your task.</Body>
<ReminderDueBy>2013-07-04T14:45:00.000</ReminderDueBy>
<ReminderIsSet>true</ReminderIsSet>
<ReminderMinutesBeforeStart>15</ReminderMinutesBeforeStart>
<DisplayTo>user1@mail.com</DisplayTo>
<DueDate>2013-08-04T15:00:00</DueDate>
<StartDate>2013-07-04T15:00:00</StartDate>
<Status>NotStarted</Status>
</Task>
</Items>
</CreateItem>
</soap:Body>
</soap:Envelope>
But, unfortunately, something goes wrong and I obtain next server response:
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Header>
<h:ServerVersionInfo MajorVersion="14" MinorVersion="3" MajorBuildNumber="123" MinorBuildNumber="3" xmlns:h="http://schemas.microsoft.com/exchange/services/2006/types" xmlns="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"/>
</s:Header>
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<m:CreateItemResponse xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
<m:ResponseMessages>
<m:CreateItemResponseMessage ResponseClass="Error">
<m:MessageText>Set action is invalid for property.</m:MessageText>
<m:ResponseCode>ErrorInvalidPropertySet</m:ResponseCode>
<m:DescriptiveLinkKey>0</m:DescriptiveLinkKey>
<m:MessageXml>
<t:FieldURI FieldURI="item:DisplayTo"/>
</m:MessageXml>
<m:Items/>
</m:CreateItemResponseMessage>
</m:ResponseMessages>
</m:CreateItemResponse>
</s:Body>
</s:Envelope>
I will be very grateful if someone can help me with it, because I can use only SOAP requests for integrations with Exchange server and assign tasks to different users is the main goal :)
Thank you in advance.


