2013-04-02 2 views
0

리드를 만들기 위해 CRM 역학 2011 웹의 일부인 XML 요청에 문제가 있습니다.CRM 역학 2011 XML 누락 요청

다음과 같이 내가 순간에 붙어있어 코드는 다음과 같습니다 이름은 이미 내가 찾은 코드 내에서 사용할 수

  <s:Body> 
       <Create xmlns="http://schemas.microsoft.com/xrm/2011/Contracts/Services"> 
       <entity xmlns:b="http://schemas.microsoft.com/xrm/2011/Contracts" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"> 
        <b:Attributes xmlns:c="http://schemas.datacontract.org/2004/07/System.Collections.Generic"> 
         <b:KeyValuePairOfstringanyType> 
          <c:key>name</c:key> 
          <c:value i:type="d:string" xmlns:d="http://www.w3.org/2001/XMLSchema">Name Test 1</c:value> 
          <c:key>E-mail</c:key> 
          <c:value i:type="d:string" xmlns:d="http://www.w3.org/2001/XMLSchema">[email protected]</c:value> 
         </b:KeyValuePairOfstringanyType> 
        </b:Attributes> 
        <b:EntityState i:nil="true"/> 
        <b:FormattedValues xmlns:c="http://schemas.datacontract.org/2004/07/System.Collections.Generic"/> 
        <b:Id>00000000-0000-0000-0000-000000000000</b:Id> 
        <b:LogicalName>account</b:LogicalName> 
        <b:RelatedEntities xmlns:c="http://schemas.datacontract.org/2004/07/System.Collections.Generic"/> 
       </entity> 
       </Create> 
      </s:Body> 
, 나는 이메일 속성을 추가하려고

(심지어 주소) 하지만 CRM의 이름 이외의 아무것도, 정확히 코드의 오류가 무엇입니까? 어떻게 수정해야합니까?

도움을 주신 모든 분들께 감사드립니다.

답변

1

표시 이름 (전자 메일 대신 emailaddress1) 대신 논리 이름을 사용해야한다고 생각합니다. 또한 전송하려는 특성의 배열이므로 보낼 각 특성에 대해 KeyValuePair 노드가 있어야한다고 생각합니다. 대신 다음을 시도하십시오.

<b:KeyValuePairOfstringanyType> 
    <c:key>name</c:key> 
    <c:value i:type="d:string" xmlns:d="http://www.w3.org/2001/XMLSchema">Name Test 1</c:value> 
</b:KeyValuePairOfstringanyType> 
<b:KeyValuePairOfstringanyType> 
    <c:key>emailaddress1</c:key> 
    <c:value i:type="d:string" xmlns:d="http://www.w3.org/2001/XMLSchema">[email protected]</c:value> 
</b:KeyValuePairOfstringanyType> 
+0

고맙습니다. 저를 위해 해결해 주셔서 감사합니다. 다시 http://stackoverflow.com/questions/15786840/add-value-to-lookup-field-in-crm-dynamics-2011 감사 : 은 솔직히 나는 당신이 한 번 봐 걸릴 수 있습니다 경우 또 다른 질문이 있습니다 앤디. –