January 30, 2020
Hello all!
I'm trying to use MkDir to create a folder in SharePoint, but I'm getting a Run-time error '76': Path not found. I've created a macro to save a copy of the file in that directory so I don't think the formatting is incorrect as far as spaces, slashes, etc.
Below is a sample code
NOTES: On my actual document, I have the year in a range from a different sheet. Below would be the result (just to make things simple) if it was a new year. I've also tried the year with the slash after (/2020/) but still the same error.
Sub create_archivefolder ()
' Create year folder if needed
Dim archive As String
archive="https://company.sharepoint.com/teams/teamname/Shared Documents/General/report/Archive/2021" 'creates a new year
On Error Resume Next 'Resumes if archive already exists
MkDir (archive)
End Sub
Thanks in advance!
Ken
February 20, 2020
Good afternoon,
I don't know the answer, because I never used Sharepoint
but try to see if this can help you in any way
https://stackoverflow.com/ques.....sharepoint
Miguel,
1 Guest(s)