如何在事件上更新MeetingTimeZone? [英] How to update MeetingTimeZone on event?

查看:73
本文介绍了如何在事件上更新MeetingTimeZone?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



在更改活动时间时,我还会尝试更改MeetingTimeZone以反映重新安排时选择的时区。但是,更新后,Outlook中的时区信息保持在更新之前。

托管Outlook客户端的Windows计算机设置为浪漫标准时间。当我随后创建具有请求/响应的会议时,outlook中的时区字段正确显示东部时间(美国和加拿大)。然后,我执行下面显示的更新,并期望将时区字段更改为太平洋时间(美国和加拿大),但字段仍为东部时间(美国和加拿大)。我在这里错过了一些东西吗?

Mads

CreateItem Request

<?xml version ='1.0'coding ='UTF-8'?> 
< soapenv:Envelope xmlns:soapenv =" http://schemas.xmlsoap.org/soap/envelope/">
< soapenv:Header>
< RequestServerVersion
xmlns =" http://schemas.microsoft.com/exchange/services/2006/types"
Version =" Exchange2007_SP1" />
< / soapenv:标题>
< soapenv:Body>
< CreateItem
xmlns =" http://schemas.microsoft.com/exchange/services/2006/messages"
SendMeetingInvitations =" SendToNone" MessageDisposition = QUOT; SaveOnly">
< SavedItemFolderId>
< DistinguishedFolderId
xmlns =" http://schemas.microsoft.com/exchange/services/2006/types"
Id =" calendar" />
< / SavedItemFolderId>
< Items>
< CalendarItem
xmlns =" http://schemas.microsoft.com/exchange/services/2006/types">
< Subject> Meeting NY< / Subject>
<灵敏度>正常< /灵敏度>
< ReminderIsSet> false< / ReminderIsSet>
< Start> 2009-10-21T12:00:00.000-04:00< / Start>
< End> 2009-10-21T14:00:00.000-04:00< / End>
< IsAllDayEvent> false< / IsAllDayEvent>
< MeetingTimeZone TimeZoneName =" Eastern Standard Time" />
< / CalendarItem>
< / Items>
< / CreateItem>
< / soapenv:Body>
< / soapenv:Envelope>






CreateItem响应



<?xml version =" 1.0"编码= QUOT; UTF-8英寸;?> 
< soap:Envelope xmlns:soap =" http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi =" http://www.w3.org/2001/XMLSchema-instance"的xmlns:XSD = QUOT; HTTP://www.w3.org/2001/XMLSchema">
< soap:Header>
< t:ServerVersionInfo MajorVersion =" 8"
MinorVersion =" 1" MajorBuildNumber = QUOT; 393" MinorBuildNumber = QUOT 1 QUOT;
Version =" Exchange2007_SP1"的xmlns:T =" HTTP://schemas.microsoft.com/exchange/services/2006/types" />
< / soap:Header>
< soap:Body>
< m:CreateItemResponse
xmlns:t =" http://schemas.microsoft.com/exchange/services/2006/types"
xmlns:m =" http://schemas.microsoft.com/exchange/services/2006/messages">
< m:ResponseMessages>
< m:CreateItemResponseMessage
ResponseClass =" Success">
< m:ResponseCode> NoError< / m:ResponseCode>
< m:Items>
< t:CalendarItem>
将T:ITEMID
编号= QUOT; AAMkADEzMjRlMTcxLWMzMTMtNGE2OC1iNTAyLTcyNmQ2ZTI3OGJmNQBGAAAAAADbQqKAQkbqToioeaM2rwrMBwCHS94bRKbyRKd5UqImf2JbBI3gBEpkAACHS94bRKbyRKd5UqImf2JbBVoggGbMAAA = QUOT;
ChangeKey =" DwAAABYAAACHS94bRKbyRKd5UqImf2JbBVoggT4c" />
< / t:CalendarItem>
< / m:Items>
< / m:CreateItemResponseMessage>
< / m:ResponseMessages>
< / m:CreateItemResponse>
< / soap:Body>
< / soap:Envelope>






UpdateItem请求


<?xml version ='1.0'coding ='UTF-8'?> 
< soapenv:Envelope xmlns:soapenv =" http://schemas.xmlsoap.org/soap/envelope/">
< soapenv:Header>
< RequestServerVersion
xmlns =" http://schemas.microsoft.com/exchange/services/2006/types"
Version =" Exchange2007_SP1" />
< / soapenv:标题>
< soapenv:Body>
< UpdateItem
xmlns =" http://schemas.microsoft.com/exchange/services/2006/messages"
SendMeetingInvitationsOrCancellations =" SendToAllAndSaveCopy"
ConflictResolution =" AlwaysOverwrite" MessageDisposition = QUOT; SaveOnly">
< SavedItemFolderId>
< DistinguishedFolderId
xmlns =" http://schemas.microsoft.com/exchange/services/2006/types"
Id =" calendar" />
< / SavedItemFolderId>
< ItemChanges>
< ItemChange
xmlns =" http://schemas.microsoft.com/exchange/services/2006/types">
< ItemId ChangeKey =" DwAAABYAAACHS94bRKbyRKd5UqImf2JbBVoggT6c"
Id =" AAMkADEzMjRlMTcxLWMzMTMtNGE2OC1iNTAyLTcyNmQ2ZTI3OGJmNQBGAAAAAADbQqKAQkbqToioeaM2rwrMBwCHS94bRKbyRKd5UqImf2JbBI3gBEpkAACHS94bRKbyRKd5UqImf2JbBVoggGbMAAA =" />
<更新>
< SetItemField>
< FieldURI FieldURI =" item:Subject" />
< CalendarItem>
< Subject> Meeting NY< / Subject>
< / CalendarItem>
< / SetItemField>
< SetItemField>
< FieldURI FieldURI =" calendar:Location" />
< CalendarItem>
<位置/>
< / CalendarItem>
< / SetItemField>
< SetItemField>
< FieldURI FieldURI =" item:Sensitivity" />
< CalendarItem>
<灵敏度>正常< /灵敏度>
< / CalendarItem>
< / SetItemField>
< SetItemField>
< FieldURI FieldURI =" calendar:Start" />
< CalendarItem>
< Start> 2009-10-22T08:00:00.000-07:00< / Start>
< / CalendarItem>
< / SetItemField>
< SetItemField>
< FieldURI FieldURI =" calendar:MeetingTimeZone" />
< CalendarItem>
< MeetingTimeZone xmlns:xsd =" http://www.w3.org/2001/XMLSchema"
xmlns:m =" http://schemas.microsoft.com/exchange/services/2006/messages"
xmlns:soap =" http://schemas.xmlsoap.org/soap/envelope/"
xmlns:t =" http://schemas.microsoft.com/exchange/services/2006/types"
xmlns:xsi =" http://www.w3.org/2001/XMLSchema-instance"
TimeZoneName =" Pacific Standard Time" />
< / CalendarItem>
< / SetItemField>
< SetItemField>
< FieldURI FieldURI =" calendar:End" />
< CalendarItem>
< End> 2009-10-22T09:00:00.000-07:00< / End>
< / CalendarItem>
< / SetItemField>
< SetItemField>
< FieldURI FieldURI =" item:ReminderIsSet" />
< CalendarItem>
< ReminderIsSet> false< / ReminderIsSet>
< / CalendarItem>
< / SetItemField>
< DeleteItemField>
< FieldURI FieldURI =" item:Body" />
< / DeleteItemField>
< DeleteItemField>
< FieldURI FieldURI =" calendar:RequiredAttendees" />
< / DeleteItemField>
< DeleteItemField>
< FieldURI FieldURI =" calendar:OptionalAttendees" />
< / DeleteItemField>
< DeleteItemField>
< FieldURI FieldURI =" calendar:Resources" />
< / DeleteItemField>
< /更新>
< / ItemChange>
< / ItemChanges>
< / UpdateItem>
< / soapenv:Body>
< / soapenv:Envelope>






UpdateItem响应

<?xml version =" 1.0"编码= QUOT; UTF-8英寸;?> 
< soap:Envelope xmlns:soap =" http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi =" http://www.w3.org/2001/XMLSchema-instance"的xmlns:XSD = QUOT; HTTP://www.w3.org/2001/XMLSchema">
< soap:Header>
< t:ServerVersionInfo MajorVersion =" 8"
MinorVersion =" 1" MajorBuildNumber = QUOT; 393" MinorBuildNumber = QUOT 1 QUOT;
Version =" Exchange2007_SP1"的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
编号= QUOT; AAMkADEzMjRlMTcxLWMzMTMtNGE2OC1iNTAyLTcyNmQ2ZTI3OGJmNQBGAAAAAADbQqKAQkbqToioeaM2rwrMBwCHS94bRKbyRKd5UqImf2JbBI3gBEpkAACHS94bRKbyRKd5UqImf2JbBVoggGbMAAA = QUOT;
ChangeKey =" DwAAABYAAACHS94bRKbyRKd5UqImf2JbBVoggT6o" />
< / t:CalendarItem>
< / m:Items>
< m:ConflictResults>
< t:计数> 0< / t:计数>
< / m:ConflictResults>
< / m:UpdateItemResponseMessage>
< / m:ResponseMessages>
< / m:UpdateItemResponse>
< / soap:Body>
< / soap:Envelope>



解决方案

不确定是否尝试过反复出现的大师?它只会在重复出现的定期主人身上返回。


FYI: MeetingTimeZone 用于为日历项目分配时区。 MeetingTimeZone 将仅在定期主服务器上返回,因此对 GetItem Web方法的任何调用都要求日历:MeetingTimeZone 属性将返回<除非正在提取的日历项上的 CalendarItemType 值设置为 RecurringMaster ,否则响应中的em> MeetingTimeZone 元素。您可以使用 MeetingTimeZone 属性在日历项目上设置时区这一事实非常重要。如果该日历项是定期主数据,则需要在日历项上设置时区。因此,如果客户端在项目创建期间未提供 MeetingTimeZone ,则Exchange Web服务将为新的定期主服务器分配默认时区。

参考: http://msdn.microsoft.com/en-us/library/cc500380.aspx


Hi,

When changing the time of an event, I also try to change the MeetingTimeZone to reflect the time zone selected when doing the reschedule. However, after the update the time zone info in Outlook stays to what is was before the update.

The Windows machine hosting the Outlook client is set to Romance Standard Time. When I then create a meeting with request/response as below, the time zone field in outlook correctly shows Eastern Time (US & Canada). I then do the update shown below and expect to see the time zone field to be changed to Pacific Time (US & Canada) but the fields stay as Eastern Time (US & Canada). Am I missing something here?

regards
Mads

CreateItem Request

<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
	<soapenv:Header>
		<RequestServerVersion
			xmlns="http://schemas.microsoft.com/exchange/services/2006/types"
			Version="Exchange2007_SP1" />
	</soapenv:Header>
	<soapenv:Body>
		<CreateItem
			xmlns="http://schemas.microsoft.com/exchange/services/2006/messages"
			SendMeetingInvitations="SendToNone" MessageDisposition="SaveOnly">
			<SavedItemFolderId>
				<DistinguishedFolderId
					xmlns="http://schemas.microsoft.com/exchange/services/2006/types"
					Id="calendar" />
			</SavedItemFolderId>
			<Items>
				<CalendarItem
					xmlns="http://schemas.microsoft.com/exchange/services/2006/types">
					<Subject>Meeting NY</Subject>
					<Sensitivity>Normal</Sensitivity>
					<ReminderIsSet>false</ReminderIsSet>
					<Start>2009-10-21T12:00:00.000-04:00</Start>
					<End>2009-10-21T14:00:00.000-04:00</End>
					<IsAllDayEvent>false</IsAllDayEvent>
					<MeetingTimeZone TimeZoneName="Eastern Standard Time" />
				</CalendarItem>
			</Items>
		</CreateItem>
	</soapenv:Body>
</soapenv:Envelope>






CreateItem 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="393" MinorBuildNumber="1"
			Version="Exchange2007_SP1" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" />
	</soap:Header>
	<soap:Body>
		<m:CreateItemResponse
			xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"
			xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages">
			<m:ResponseMessages>
				<m:CreateItemResponseMessage
					ResponseClass="Success">
					<m:ResponseCode>NoError</m:ResponseCode>
					<m:Items>
						<t:CalendarItem>
							<t:ItemId
								Id="AAMkADEzMjRlMTcxLWMzMTMtNGE2OC1iNTAyLTcyNmQ2ZTI3OGJmNQBGAAAAAADbQqKAQkbqToioeaM2rwrMBwCHS94bRKbyRKd5UqImf2JbBI3gBEpkAACHS94bRKbyRKd5UqImf2JbBVoggGbMAAA="
								ChangeKey="DwAAABYAAACHS94bRKbyRKd5UqImf2JbBVoggT4c" />
						</t:CalendarItem>
					</m:Items>
				</m:CreateItemResponseMessage>
			</m:ResponseMessages>
		</m:CreateItemResponse>
	</soap:Body>
</soap:Envelope>





UpdateItem Request


<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
	<soapenv:Header>
		<RequestServerVersion
			xmlns="http://schemas.microsoft.com/exchange/services/2006/types"
			Version="Exchange2007_SP1" />
	</soapenv:Header>
	<soapenv:Body>
		<UpdateItem
			xmlns="http://schemas.microsoft.com/exchange/services/2006/messages"
			SendMeetingInvitationsOrCancellations="SendToAllAndSaveCopy"
			ConflictResolution="AlwaysOverwrite" MessageDisposition="SaveOnly">
			<SavedItemFolderId>
				<DistinguishedFolderId
					xmlns="http://schemas.microsoft.com/exchange/services/2006/types"
					Id="calendar" />
			</SavedItemFolderId>
			<ItemChanges>
				<ItemChange
					xmlns="http://schemas.microsoft.com/exchange/services/2006/types">
					<ItemId ChangeKey="DwAAABYAAACHS94bRKbyRKd5UqImf2JbBVoggT6c"
						Id="AAMkADEzMjRlMTcxLWMzMTMtNGE2OC1iNTAyLTcyNmQ2ZTI3OGJmNQBGAAAAAADbQqKAQkbqToioeaM2rwrMBwCHS94bRKbyRKd5UqImf2JbBI3gBEpkAACHS94bRKbyRKd5UqImf2JbBVoggGbMAAA=" />
					<Updates>
						<SetItemField>
							<FieldURI FieldURI="item:Subject" />
							<CalendarItem>
								<Subject>Meeting NY</Subject>
							</CalendarItem>
						</SetItemField>
						<SetItemField>
							<FieldURI FieldURI="calendar:Location" />
							<CalendarItem>
								<Location />
							</CalendarItem>
						</SetItemField>
						<SetItemField>
							<FieldURI FieldURI="item:Sensitivity" />
							<CalendarItem>
								<Sensitivity>Normal</Sensitivity>
							</CalendarItem>
						</SetItemField>
						<SetItemField>
							<FieldURI FieldURI="calendar:Start" />
							<CalendarItem>
								<Start>2009-10-22T08:00:00.000-07:00</Start>
							</CalendarItem>
						</SetItemField>
						<SetItemField>
							<FieldURI FieldURI="calendar:MeetingTimeZone" />
							<CalendarItem>
								<MeetingTimeZone xmlns:xsd="http://www.w3.org/2001/XMLSchema"
									xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"
									xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
									xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"
									xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
									TimeZoneName="Pacific Standard Time" />
							</CalendarItem>
						</SetItemField>
						<SetItemField>
							<FieldURI FieldURI="calendar:End" />
							<CalendarItem>
								<End>2009-10-22T09:00:00.000-07:00</End>
							</CalendarItem>
						</SetItemField>
						<SetItemField>
							<FieldURI FieldURI="item:ReminderIsSet" />
							<CalendarItem>
								<ReminderIsSet>false</ReminderIsSet>
							</CalendarItem>
						</SetItemField>
						<DeleteItemField>
							<FieldURI FieldURI="item:Body" />
						</DeleteItemField>
						<DeleteItemField>
							<FieldURI FieldURI="calendar:RequiredAttendees" />
						</DeleteItemField>
						<DeleteItemField>
							<FieldURI FieldURI="calendar:OptionalAttendees" />
						</DeleteItemField>
						<DeleteItemField>
							<FieldURI FieldURI="calendar:Resources" />
						</DeleteItemField>
					</Updates>
				</ItemChange>
			</ItemChanges>
		</UpdateItem>
	</soapenv:Body>
</soapenv:Envelope>





UpdateItem 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="393" MinorBuildNumber="1"
			Version="Exchange2007_SP1" 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="AAMkADEzMjRlMTcxLWMzMTMtNGE2OC1iNTAyLTcyNmQ2ZTI3OGJmNQBGAAAAAADbQqKAQkbqToioeaM2rwrMBwCHS94bRKbyRKd5UqImf2JbBI3gBEpkAACHS94bRKbyRKd5UqImf2JbBVoggGbMAAA="
								ChangeKey="DwAAABYAAACHS94bRKbyRKd5UqImf2JbBVoggT6o" />
						</t:CalendarItem>
					</m:Items>
					<m:ConflictResults>
						<t:Count>0</t:Count>
					</m:ConflictResults>
				</m:UpdateItemResponseMessage>
			</m:ResponseMessages>
		</m:UpdateItemResponse>
	</soap:Body>
</soap:Envelope>


解决方案

Not sure you try the property with recurring masters? It will be returned only on recurring recurring masters.

FYI: MeetingTimeZone is used to assign a time zone to a calendar item. The MeetingTimeZone will be returned only on recurring masters, so any call to a GetItem Web method asking for the calendar:MeetingTimeZone property will return no MeetingTimeZone element in the response unless the CalendarItemType value on the calendar item being fetched is set to RecurringMaster. The fact that you can set a time zone on a calendar item using the MeetingTimeZone property is important. Having a time zone set on a calendar item is required if that calendar item is a recurring master. As such, if a MeetingTimeZone is not provided by the client during item creation, Exchange Web Services will assign a default time zone to the new recurring master.

Reference: http://msdn.microsoft.com/en-us/library/cc500380.aspx


这篇关于如何在事件上更新MeetingTimeZone?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆