title: c# byte array xml serialization
body: <p>I got a byte array</p>
  
  <pre><code>public byte[] values;
  </code></pre>
  
  <p>I fill it with data </p>
  
  <pre><code>new byte[64];
  </code></pre>
  
  <p>I serialize it and I get the following XML part:</p>
  
  <pre><code>&lt;values&gt;
  AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==
  &lt;/values&gt;
  </code></pre>
  
  <p>I found the following solution here in SO:</p>
  
  <pre><code>[XmlElement("values", DataType = "hexBinary")]
          public byte[] values;
  </code></pre>
  
  <p>Now I get the same XML as above just with "0" instead of "A".</p>
  
  <p>When I serialize e.g. a Int16/Int32/sbyte array. I get something like this in XML:</p>
  
  <pre><code>&lt;values&gt;0&lt;/values&gt;
  &lt;values&gt;0&lt;/values&gt;
  &lt;values&gt;0&lt;/values&gt;
  </code></pre>
  
  <p>In a <strong>vertical</strong> arrangement.</p>
  
  <p>Now my question: <em>Is it possible to get a byte array also in a vertical arrangement?</em> Like:</p>
  
  <pre><code>    &lt;values&gt;00&lt;/values&gt;
      &lt;values&gt;00&lt;/values&gt;
      &lt;values&gt;00&lt;/values&gt;
  </code></pre>
  
  <p>Mark</p>