title: Not working .docx conversion to blob in angularjs
body: <p>I saving a files( .txt, .docx, .pdf) in a database  using varbinary(MAX) datatype successfully.</p>
  
  <p>Now i am using below code for downloading files from a database. 
  I am able to download .txt extension file without any problem.
   <strong>When i tried to download .docx extenstion file  not working as expected. the data is coming as junk characters and word document not able to open <em>"because we found a problem with its content"</em>.</strong></p>
  
  <pre><code>$http(request).success(function (d, status, headers) {
      head = headers();
  
      var contentType = head['content-type'];
  
      var contentdisposition = head['content-disposition'];
      var fileName = contentdisposition.split(';')[1].trim().split('=')[1];
      fileName = fileName.replace(/"/g, '');
      console.log('calling');
      var contentType = head['content-type'];
  
      var data = d;
  
      var file = new Blob([data], { type: contentType });
      saveAs(file, fileName);
  })
  .error(function () {
  
  });
  </code></pre>