I have SharePoint 2013 doc library, I want to map this library with power shell 'and then I can run a script that see it as a folder and copy files to anther NTFS folder.
SharePoint library link is : "http://sitename/abigail/Shared Documents"
I tried to use New-PSDrive and I get error:
"New-PSDrive : Drive root "http://sitename/abigail/Shared Documents" does not exist or it is not a folder."
Need help with this issue/
All the links above explain how to map the SharePoint folder from GUI when the user is logged in.
I need this with a script that will run when the user will not be logged in.
the script will map the SharePoint folder and will copy a specific file to the destination folder.
SharePoint 2019 is attached via the WebClient WebDAV.
This is not a PowerShell issue or limitation. it's a Windows specific permissions requirement. You must be logged onto / into a resource, in this case, SP / SPO, with an account that has permissions to do X or Y with any resource, unless you are allowing anonymous access (not advisable, btw) and of course mappings are user specific.