title: Permissions error on FSO DeleteFile/MoveFile
body: <p>I'm trying to delete/move a file using classic asp fso but I'm getting this error:</p>
  
  <pre><code>Microsoft VBScript runtime error '800a0046'
  
  Permission denied
  </code></pre>
  
  <p>The file is located in <code>c:\files\test\file.txt</code> and ultimately I want to move it to <code>c:\archive\file.txt</code></p>
  
  <p>I started out with <strong>Move</strong> but I got the error. Then I split it up into <strong>Copy</strong> and <strong>Delete</strong>. The copying went fine but still the same error on <strong>Delete</strong>.</p>
  
  <p>I ruled out the <strong>Delete</strong> method because I was able to use <strong>Delete</strong> on the file in the 'archive' folder using this code:</p>
  
  <pre><code>dim fs,f
  set fs=Server.CreateObject("Scripting.FileSystemObject")
  set f=fs.GetFile("C:\archive\file.txt")
  f.Delete
  set f=nothing
  set fs=nothing
  </code></pre>
  
  <p>I also double-checked the permissions on both folders and they're exactly the same for IIS_IUSRS: Read&amp;Execute, List folder contents, Read, Write are checked. I tried giving Modify rights as well but that made no difference.</p>
  
  <p>Finally, I checked the file's attributes and it came back as 32 (Archive). I also tried to force the delete:</p>
  
  <pre><code>fso.DeleteFile FileName, true
  </code></pre>