我正在为iOS移动应用程序开发Web服务(使用Java),并且作为要求的一部分,需要在SharePoint中获得所有已定义的Calender事件的所有重复。我能够为此生成所有存根,并使用getListItems
方法获取 日历事件列表 ,而不会出现任何问题。但是我无法使用此方法来获取 经常性 数据。我尝试了许多不同的查询和查询选项参数,并且每次失败时都会javax.xml.ws.soap.SOAPFaultException
。
使用getListItems
方法我可以像这样检索日历事件列表,但不能检索 重复 :
<z:row ows_Created="2012-03-30 17:07:49"
ows_EndDate="2012-06-04 16:30:00"
ows_EventDate="2012-04-02 14:00:00"
ows_FSObjType="881;#0"
ows_FileRef="881;#teamsite/SCM/Lists/CIG ISTQA Build Deployment Calender/881_.000"
ows_ID="881" ows_MetaInfo="881;#"
ows_Title="IST7 (COL + nJPMOL) - September PnT PH2 Early IST "
ows_UniqueId="881;#{3F79DE4B-7609-4559-9176-3F8598CEC45B}"
ows__Level="1" ows__ModerationStatus="0"
ows_fAllDayEvent="0" ows_fRecurrence="1"
ows_owshiddenversion="2"/>
我也尝试了以下链接中的所有选项,并因同样的异常而失败。
Expand recurring events from a Sharepoint calendar over webservices
我使用getListItems
方法尝试了所有这些查询:
<Where><Or><And><Geq>
<FieldRefName='EventDate'/>
<ValueType='DateTime'StorageTZ='TRUE'>
<Today/></Value></Geq><Leq>
<FieldRefName='EventDate'/>
<ValueType='DateTime'StorageTZ='TRUE'>
<Today/></Value></Leq></And><And><Leq>
<FieldRefName='EventDate'/>
<ValueType='DateTime'StorageTZ='TRUE'><Today/>
</Value></Leq><Geq><FieldRefName='EndDate'/>
<ValueType='DateTime'StorageTZ='TRUE'>
<Today/></Value></Geq></And></Or></Where>";
<Where><DateRangesOverlap>
<FieldRef Name=\"EventDate\" />
<FieldRef Name=\"EndDate\" />
<FieldRef Name=\"RecurrenceID\" />
<Value Type='DateTime'><Year/></Value>
</DateRangesOverlap></Where>";
<Where><DateRangesOverlap>
<FieldRef Name=\"EventDate\" />
<FieldRef Name=\"EndDate\" />
<FieldRef Name=\"RecurrenceID\" />
<Value Type=\"DateTime\"><Month />
</Value></DateRangesOverlap></Where>";
<Where><DateRangesOverlap>
<FieldRef Name=\"EventDate\" />
<FieldRef Name=\"EndDate\" />
<FieldRef Name=\"RecurrenceID\" />
<Value Type=\"DateTime\"><Month/>
</Value></DateRangesOverlap>
</Where><OrderBy><FieldRef Name='ID' /></OrderBy>";
AND查询选项:
<ExpandRecurrence>TRUE</ExpandRecurrence>
<CalendarDate>2012-05-01T00:00:00Z</CalendarDate>
<ViewAttributes Scope=\"RecursiveAll\" />";
<IncludeMandatoryColumns>FALSE</IncludeMandatoryColumns>
<DateInUtc>TRUE</DateInUtc><ViewAttributes Scope=\"Recursive \"/>
<RecurrencePatternXMLVersion>v3</RecurrencePatternXMLVersion>
<ExpandRecurrence>True</ExpandRecurrence>
<CalendarDate>2011-10-16T00:00:00Z</CalendarDate>
<RecurrenceOrderBy>TRUE</RecurrenceOrderBy>
<ViewAttributes Scope=\"RecursiveAll\"/>";
<ExpandRecurrence>TRUE</ExpandRecurrence>";
但是他们都没有工作,并且失败了javax.xml.ws.soap.SOAPFaultException
。
有人可以帮我提取这些重复数据吗?还有其他办法吗?可以使用Java获取它吗?
答案 0 :(得分:0)