title: How to check if an ASP.Net File Upload Control has a file in JQuery?
body: <p>So I'm writing a custom validator and I need to check if a file has been uploaded using the asp.net File Upload Control.</p>
  
  <p>So far I have:</p>
  
  <pre><code>function validate(sender, args)
  {
      if ($('#&lt;%= hdnID.ClientID%&gt;').val() != "False")
      {
          args.IsValid = true;
      }
      else
      {
          if ($('#&lt;%= fup.ClientID %&gt;').val() != '' )
          {
              alert("Run some code here");
          }
          else
          { }
      }
   }
  </code></pre>
  
  <p>The bit that is not right is </p>
  
  <pre><code>if ($('#&lt;%= fup.ClientID %&gt;').val() != '' )
  </code></pre>
  
  <p>I'm not sure how to determine whether the control has a file or not.
  Any suggestions would be awesome. Thanks. </p>