Can I copy files to a Network Place from a script or the command line? [closed]

By : Abs

Is it possible, in Windows XP, to copy files to a Network Place from the command line, a batch file or, even better, a PowerShell script?

What sent me down this road of research was trying to publish files to a WSS 3.0 document library from a user's machine. I can't map a drive to the library in question because the WSS site is only available to authenticate via NTLM on a port other than 80 or 443. I suppose I could alternately use the WSS web services to push the files out, but I'm really curious about the answer to this question now.

By : Abs


If you are referring to a windows box, just use xcopy. It is pretty standard to have xcopy available.

xcopy src \\dest-machine\shared-library-name\dest
xcopy \\src-machine\shared-library-name\dest src
By : jetzdax

"Network Places" doesn't really have an API, it's just a bunch of shortcuts, and the SharePoint share uses a Shell Extension, if I recall correctly.

All of that to say: accessing Sharepoint as a file system from PowerShell also requires an extension, the SharePoint Provider.

By : Jaykul

From what I'm seeing, it seems that it's not possible to directly access/ manipulate a Network Place from the command line, be it in PowerShell or the plain ol' command prompt.

@slipsec (#13899): Thanks for the suggestion, but PowerShell doesn't support the port number in the destination path any more than the net use command does.

So the best thing I can figure to do in my particular situation is bite the bullet and buy something like WebDrive to enable drive mapping via WebDAV on non-standard ports, or do some different configuration (e.g. separate web app with a different IP address and host headers) in SharePoint to expose the site via NTLM on a standard port.

By : Abs

This video can help you solving your question :)
By: admin