title: Cannot read file uploaded in c# handler
body: <p>I'm trying to upload a file to a handler in c# but it seems as though the file is not getting uploaded. Calling <code>Request.Files["fileNameHere"]</code> returns null</p>
  
  <p>My html code:</p>
  
  <pre><code>&lt;form id="importManagerForm" action="../ImportManager.ashx" method="POST"&gt;
     &lt;input name="selectedFile" id="selectedFile" type="file" /&gt; 
     &lt;input type="submit" value="submit"/&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>And the code in the ashx handler is:</p>
  
  <pre><code>public void ProcessRequest(HttpContext context)
  {
    var importFile = context.Request.Files["selectedFile"]; //This part returns null
    var fileName = new Guid().ToString() + ".csv";
    importFile.SaveAs(fileName);
  }
  </code></pre>
  
  <p>Any idea what's the problem?</p>
  
  <p>UPDATE:</p>
  
  <p>A quick debug on <code>context.Request.Files</code> showed me a file count of 0.</p>