title: Upload multiple files from Powershell script
body: <p>I have a webapplication that can process POSTing of a html form like this:</p>
  
  <pre><code>&lt;form action="x" method="post" enctype="multipart/form-data"&gt;
    &lt;input name="xfa" type="file"&gt;
    &lt;input name="pdf" type="file"&gt;
    &lt;input type="submit" value="Submit"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Note that there are two <code>type="file"</code> <code>&lt;input&gt;</code> elements. </p>
  
  <p>How can I script POSTing this from a Powershell script? I plan to do that to create a simple test-framework for the service.</p>
  
  <p>I found <a href="http://msdn.microsoft.com/en-us/library/system.net.webclient.uploadfile%28v=vs.110%29.aspx">WebClient.UploadFile()</a>, but that can only handle a single file.</p>
  
  <p>Thank you for taking your time.</p>