0

これは私にとって本当に不可解でした。2 日前、次のような制限を使用して、すべての EWS ファイルで php-ews を完全に動作させました。

$start = new DateTime('2014-06-05');

$Request->Restriction = new EWSType_RestrictionType();
$Request->Restriction->And = new EWSType_AndType();

$Request->Restriction->And->IsGreaterThan = new EWSType_IsGreaterThanType();
$Request->Restriction->And->IsGreaterThan->FieldURI = new stdClass;
$Request->Restriction->And->IsGreaterThan->FieldURI->FieldURI = 'item:DateTimeSent';
$Request->Restriction->And->IsGreaterThan->FieldURIOrConstant->Constant->Value = $start->format('c');

現在、このスクリプトを実行しようとすると、タイトルにエラー メッセージが表示されます。確認したところ、私のファイルには SearchExpression と SearchExpressionType への参照が含まれています。

必要に応じて、私の wsdl ファイルと xsd ファイルを喜んで投稿します。このエラーの原因は何ですか?

PS私はexhange 2013を使用していますが、制限なしでメールを問題なく受信できます。

4

2 に答える 2

0

私は同じ問題を抱えています... services.wsdlで2010年と2013年の間に違いがあることがわかりました。したがって、リクエストは異なる必要があります。しかし、私はまだ解決策を見つけていません。

2010:

<!-- The type of object which actually encodes a restriction -->
  <xs:complexType name="RestrictionType">
    <xs:choice maxOccurs ="unbounded">
      <xs:element ref="t:Contains"/>
      <xs:element ref="t:Excludes"/>
      <xs:element ref="t:Exists"/>
      <xs:element ref="t:IsEqualTo"/>
      <xs:element ref="t:IsNotEqualTo"/>
      <xs:element ref="t:IsGreaterThan"/>
      <xs:element ref="t:IsGreaterThanOrEqualTo"/>
      <xs:element ref="t:IsLessThan"/>
      <xs:element ref="t:IsLessThanOrEqualTo"/>
      <xs:element ref="t:And"/>
      <xs:element ref="t:Not"/>
      <xs:element ref="t:Or"/>
    </xs:choice>
  </xs:complexType>

2013:

 <!-- The type of object which actually encodes a restriction -->
  <xs:complexType name="RestrictionType">
    <xs:sequence>
      <xs:element ref="t:SearchExpression"/>
    </xs:sequence>
  </xs:complexType>
于 2014-07-08T07:51:49.727 に答える