Hello,
A project I'm working on has a button that is supposed to create a static, macro free copy of the workbook and save it to the folder which is located on OneDrive. This button will be used by multiple users, not just me. I have this coded and it works perfectly whenever I test it, but when someone else tries they get Run-time error '1004'. I could just take out the part where it auto-saves and just have it create the copy, but that is not ideal and I know there has to be something I am mis-keying to cause the problem.
Here is my code for this piece of the process that works for me but no one else:
Of course I substitute my user name and company name into the file path. I did find this other thread which runs along similar lines, but applying it to my own code did not resolve the issue.
A project I'm working on has a button that is supposed to create a static, macro free copy of the workbook and save it to the folder which is located on OneDrive. This button will be used by multiple users, not just me. I have this coded and it works perfectly whenever I test it, but when someone else tries they get Run-time error '1004'. I could just take out the part where it auto-saves and just have it create the copy, but that is not ideal and I know there has to be something I am mis-keying to cause the problem.
Here is my code for this piece of the process that works for me but no one else:
Code:
ActiveWorkbook.SaveAs FileName:="C:\Users\USERNAME\OneDrive - COMPANY NAME\Postcard Sales (" & Format(Now, "yyyy-mm-dd") & ").xlsx"
Of course I substitute my user name and company name into the file path. I did find this other thread which runs along similar lines, but applying it to my own code did not resolve the issue.