Move File activity not working for files in mapped network drive

@Hisuhong , is it possible to change the filename as to be without spaces?
Ex Cust_3_CAD_Customer_Form.xlsm ?

All the tests i ran had the filename w/o spaces, maybe that’s the issue.

Also, if you are running the robot on a VM , does the user of the VM has read/write access to that folder?

@lfcosta I changed the filename to remove the spaces, however the same error persists, for both Move File and powershell. :cry:

I am also not running it on a VM.

@lfcosta It seems the Copy File activity works, so I may have to just use the copy file activity and delete the file in the original folder once the copy is complete. But if they Copy File activity works, I wonder why the Move File activity does not… They use the same variables and are both system.file activities…

@Hisuhong that’s weird really, but if you’re OK with using the copy activity, problem solved!

I have a couple of workflows where i used that as well. I use a “Path Exists” before doing the actual copy to prevent scenarios where the file is already there, if it is, i delete the file before the copy.

Maybe it’s just a bug, if you want to dwelve further into the matter, try updating the dependencies of the project, maybe it works… :slight_smile:

1 Like

Thank you everyone for your help!

@lfcosta It seems I actually do need the Move File activity because i have to preserve the creation date of the original file. When I use the copy activity I end up deleting the original file once I copy the file to the new folder… Do you know of another way I could move the file?

Before you Mapped the drive you had a full address of the document library…

Once you mapped it most likely became a shortened URL of the full address. Try the full address rather than the mapped address.

To ping the directory, open IE or Chrome and type the full address into the address bar and hit enter. Is the proper folder present? If not, you dont have the right folder directory to find the File you are looking to move

Check this link on how to find the full URL

@Jarzzz Yep, I tried it with the full address as well (I confirmed that it was correct). But the same error persists unfortunately, for both the file moving issue and the copy issue

@Hisuhong Try removing the file name from the Destination field. Just include the full folder path.

So /…/…/Customer/Approval_Completed/

This is for the Move File activity btw

maybe then you dont have the right permisson on the volume at that server to delete…

@Jarzzz still the same error :sob:

@bcorrea I am able to move files manually, as well as copy, delete, rename. I have full access to the files so that is why I am confused about why the Move File activity does not work… :frowning:

@Hisuhong Can you share a screenshot of the error?

when you do manually, you still using that Z drive? if so, then it is not permissions… did you try moving it in an Execute Code activity?

@bcorrea Manually, I can do it both on Sharepoint and on the Z drive.
No I have not done it in an Execute Code activity. I have never used that activity before

maybe try it so we can be sure that it is a bug in the move activity…

@bcorrea Did you mean Invoke Code?

yes, sorry…

@bcorrea I have tried it with Invoke Code, and even Invoke Method, but it still won’t work… The strange thing is the Copy File activity works so I can copy it, but when I do this it does not preserve the creation date of the original file, which is important for this automation

Then, even when it does not look like it, could be some kind of authorization issue in sharepoint, have you considered automating it directly in the sharepoint web site? or using API to move the file?

@bcorrea it is actually more inconvenient to automate it directly on the sharepoint site unfortunately. How do you use API to move the file?