Parameters in complex type missing from Soap Request
<p>I am have a very odd bug that I am trying to track down. In my code I am calling a basic web service. The issue that I am seeing certain parameters in a complex type are simply not being set, even when I set them statically.</p>

<p>When debugging the code, I have verified that the properties of the object are correctly set, this issue only happens when I generate the soap request. I am generating the soap request by using the built in web service proxy in .net (Add Webservice Reference in visual studio)</p>

<p>Any help with this is greatly appreciated.</p>

<p>The elements that are not being set in the complex type OrderTransaction are:
tracerId
orderDate
updateTime</p>

<p>Here is an example of what I am seeing:</p>

<p>I statically create the object</p>

<pre><code>orderArray[0] = new OrderTransaction();
</code></pre>

<p>I then populate a parameter in this object</p>

<pre><code>orderArray[0].tracerId = 47;
</code></pre>

<p>When I call my web service this parameter is completely missing from the complex type.'</p>

<p>Here is an example of my complex type xsd</p>

<pre><code>&lt;xs:complexType name="OrderTransaction"&gt;
&lt;xs:sequence&gt;
  &lt;xs:element minOccurs="0" name="cardType" type="xs:string" /&gt;
  &lt;xs:element name="ccEncryptedFlag" type="xs:short" /&gt;
  &lt;xs:element minOccurs="0" name="chainShortcode" type="xs:string" /&gt;
  &lt;xs:element minOccurs="0" name="channelCode" type="xs:string" /&gt;
  &lt;xs:element minOccurs="0" name="creditCardNumber" type="xs:string" /&gt;
  &lt;xs:element minOccurs="0" name="custIdMigratedToRex" type="xs:dateTime" /&gt;
  &lt;xs:element minOccurs="0" name="customerId" type="xs:long" /&gt;
  &lt;xs:element minOccurs="0" name="customerName" type="xs:string" /&gt;
  &lt;xs:element minOccurs="0" name="expirationMonth" type="xs:string" /&gt;
  &lt;xs:element minOccurs="0" name="expirationYear" type="xs:string" /&gt;
  &lt;xs:element minOccurs="0" name="orderDate" type="xs:dateTime" /&gt;
  &lt;xs:element name="orderId" type="xs:long" /&gt;
  &lt;xs:element minOccurs="0" name="provinceCode" type="xs:string" /&gt;
  &lt;xs:element name="totalItemTransactions" type="xs:short" /&gt;
  &lt;xs:element minOccurs="0" name="tracerId" type="xs:long" /&gt;
  &lt;xs:element minOccurs="0" name="updateTime" type="xs:dateTime" /&gt;
&lt;/xs:sequence&gt;
</code></pre>

<p></p>

<p>Here is my current testing code:</p>

<pre><code>            ZBatch_PublisherService.ItemTransaction[] itemArray = new ItemTransaction[1];
            ZBatch_PublisherService.OrderTransaction[] orderArray = new OrderTransaction[1];



            itemArray[0] = new ItemTransaction();
            itemArray[0].classId = 1153;

            itemArray[0].fulfillmentCenterId = 123;
            itemArray[0].fulfillmentType = "TEST";
            itemArray[0].lineItemId = 597;

            itemArray[0].migratedFlag = 0;

            itemArray[0].taxAmount = Convert.ToDecimal("7.00");
            itemArray[0].sku = "110853852";
            itemArray[0].quantity = 1;
            itemArray[0].taxService = "CSS";
            itemArray[0].totalShippingAmount = Convert.ToDecimal("5.99");
            itemArray[0].tracerId = 47;
            itemArray[0].trackingNo = "abc2134";
            itemArray[0].unitAmount = Convert.ToDecimal("79.99");
            itemArray[0].updateTime = Convert.ToDateTime("2011-10-27T17:47:30");


            orderArray[0] = new OrderTransaction();
            orderArray[0].tracerId = 47;
            orderArray[0].customerId = 15;
            orderArray[0].cardType = "VISA";
            orderArray[0].ccEncryptedFlag = 3;
            orderArray[0].chainShortcode = "ABC";
            orderArray[0].creditCardNumber = "1234566788";
            orderArray[0].customerName = "John Doe";
            orderArray[0].expirationMonth = "APR";
            orderArray[0].expirationYear = "2014";
            orderArray[0].orderDate = Convert.ToDateTime("2011-10-27T17:47:30");
            orderArray[0].orderId = 343;
            orderArray[0].provinceCode = "AB";
            orderArray[0].totalItemTransactions = 1;
            orderArray[0].updateTime = Convert.ToDateTime("2011-10-27T17:47:30");

            ZBatch_PublisherService.ZBatchPublisherServiceService ws = new ZBatchPublisherServiceService();

            ws.saveBatch(orderArray, itemArray);
</code></pre>
