FIle Polling Error - \"Could not rename file ......&amp

I have a flow executed by file polling. If an error occurs, the flow exits and signals a failure.

The file is being left in the ‘Working’ directory. A message in the server log states that the file could not be renamed from …\working… to …\error…

If I try and delete the file from the working directory (Windows XP dev box), I get an error saying the file is being used by another process. I have to re-start the IS server to release it.

I am clearing the pipeline before generating the error condition. Not sure what else I can do!?!

Any advice / pointers would be greatly appreciated.


Mark Daly.

you probably won’t like this answer but the problem most likely resides with the OS i.e. windows XP and file locking. If you can try the same thing on a different OS such as windows server and see if you get the same issue

Here is a techmail from ZDNet
moving the file to error directory would have the same issues as deleting

May 18, 2004

Delete an “undeletable” file
Staff, TechRepublic
Have you ever tried to delete a file in Windows Explorer and received the error message that it could not delete the file because it was in use? This can happen even when you know for a fact that the file is not in use.

You may open a command prompt and try to delete the file with the Delete command. But this method also fails.

Here’s how you can delete an “undeletable” file. Follow these steps:

  1. Close all open programs.
  2. Open a command prompt.
  3. Right-click the taskbar, and select Task Manager.
  4. On the Processes tab, select Explorer.exe, and click the End Process button.
  5. Minimise Task Manager, but don’t close it.
  6. At the command prompt, use the Delete command to remove the file, and close the command prompt.
  7. In Task Manager, go to File | New Task (Run).
  8. In the Create New Task dialog box, enter Explorer.exe, and click OK.
  9. Close Task Manager.

Hi Mark,

Could you share the solution for this problem?
We are using 6.5 SP1 and have the same error.