Copy file activity failing because: Copy File: The process cannot access the file ******* because it is being used by another process

Hi I am trying to copy an excel document but I am receiving an error saying the document is open or already being used, but it isn’t.

I have put 2 delays and a kill in prior and I have checked task manager and it definitely isn’t open. only accessible on my machine so not open anywhere else.

could it potentially be anything else or to do with the variables?

Are you using excel process scope before copy activity.

Also instead of delay, requesting you to use copy inside retry scope activity. Use Kill process and give argument excel in it…

1 Like

Make sure the Copy File runs before any Excel Process Scope or Excel activity touches that file. Verify that source and destination paths are different and not pointing to the same file

Note :Also check that OneDrive/antivirus is not syncing the folder and locking the file.

copy the template to a new file name and only open the copied file in Excel.

1 Like

@Rebecca_9 kindly use kill process activity before copy file activity

1 Like

Hi @Rebecca_9

Since you mentioned no one is using the file.
Check the file you are trying to move is in one drive/share point. If yes either you can disable the sync or keep the Copy file in retry scope with delay. This should resolve the issue. Let me know if you still face the issue.

1 Like

Hi @Rebecca_9

Please use kill process activity before copy the file so it will no given you the error like process being used by another process

Cheers

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.